Joined: 18 May 2016
Online Status: Offline
Posts: 22
Topic: View number of suppressed groups in Report Header Posted: 12 Oct 2016 at 8:22pm
I need some assistance here...
In my Report Header I want to display the number of unsuppressed Group Footers.
I can make it display correctly in the Report Footer. But I need it in the header.
I will call the main report MR, the subreport SR and a shared variable MyX.
Report design SR All sections are suppressed.
SR calculates MyX based on its results.
Report design MR GH Resets MyX to 0.
Contains SR in order to calculate new MyX.
"Suppress Blank Sections" is checked.
D Suppressed and empty.
GF Contains my main fields.
Contains SR again, but here the SR is edited: If MyX>0 inside the SR, then its Details' section is not suppressed.
MyX is returned here. If MyX>=0 Then GF is suppressed via Section Expert.
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Posted: 14 Oct 2016 at 8:14am
results depending on sub report shared-variables cannot be displayed in the header so continuing down that line of thought will like end up in the same dead end each time.
Consider rethinking the process, like a another sub-report in the header that can can be trimmed down or simplified to get the same result across all the groups that might appear in the report and use that instead. Meaning, if you can run one summary query that uses the same logically conditions that all of your sub reports are doing at a more detailed level you could use that instead.
Just a thought...
Joined: 18 May 2016
Online Status: Offline
Posts: 22
Posted: 14 Oct 2016 at 11:11am
So there's no way to identify a record as suppressed?
Is there a way to count empty subreports?
That subreport's data is just a stored procedure (1300 rows long, containing I think 19 queries). So maybe there's a way to skip the subreport route but I guess that would require many hours of thinking ;)
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Posted: 17 Oct 2016 at 2:55am
It is not so much an issue of counting suppressed items but that the way you are counting them is by using a shared variable. The shared variable results cannot be displayed in sections (like a report header) that precede the result of the shared variable.
If you know this as a limitation you can try to think of a different solution that can still get you the result you want, but not necessarily in the way that you were thinking of the data in the report. Meaning if you can run a separate query once that can replicate the 'group count' and run that in a report header you can bring back the result and use it anywhere in the report.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum