[fpc-pascal] fpreport: can not use two ObjectLists as datasource in one report
Michael Van Canneyt
michael at freepascal.org
Fri Mar 19 13:34:39 CET 2021
On Fri, 19 Mar 2021, Andreas Frieß via fpc-pascal wrote:
> Am 19.03.2021 um 11:07 schrieb Michael Van Canneyt via fpc-pascal:
>> On Fri, 19 Mar 2021, Michael Van Canneyt via fpc-pascal wrote:
>>> On Fri, 19 Mar 2021, Andreas Frieß via fpc-pascal wrote:
>>>> Make a Report Preview -> only the contend of the first dataset is
>>>> I will file a bug
>>> No need, because this is as designed.
>> For clarity: it's as designed, but that doesn't mean I won't consider
>> changing the design. Just don't report it as a bug, because it is not.
> For the record, is this written downwhat is 'by design' ?
No. There are testsuites and some pages in the WIKI
I obviously don't expect people to deduce the behaviour from those sources.
> For me it is a bug, because i can design a unuseable not working second
> Databand and i got no message. Nor Designtime, nor runtime.
I expected this comment, and to a certain degree I can see your point.
But for me this is more akin to 'don't put your cat in the microwave to dry it'
you can do it, but don't expect satisfactory results :-)
> If it is not
> a bug, so a featurerequest must be possible, because other reports can
> handle this without a problem.
You can definitely submit a feature request. For severity, simply select 'feature'.
In general implementing it may be not so trivial as it seems:
If there are 2 (or more) data bands, which one should I treat first ?
The one that comes first in the internal list of bands, or the one that comes first
when you visually design the report, or the dataset that comes first in the
list of report data sets ? These orderings may not be identical....
For me it is also a question whether you should first loop the data of the
first data band, and then loop the next. This is your case if I understood
An equally valid approach would be to print one data band, then the other.
Then advance both datasets. etc.
Which one to take depends on what output you need, obviously.
(which is what I remarked on in my first reply)
Then the treatment groupings must be considered, page jumps etc.
Just to say it's far from trivial.
That is why I initially suggested making a second page in the report,
because then this is all much less ambiguous.
But please submit a feature request, I will try to find a good solution.
For the time being, your approach with fake master detail will need to
More information about the fpc-pascal