Report printing lots of identical pages.

G

Guest

I built a report that is an analysis of the values in a table. I am counting
records based on one criteria and totaling based on another. I have got the
report working with the exception that I get a page printed for each record.
Seeing as the report is essentially a summary, I intend it to be giving one
or two pages instead of 22692 (one for each record in the table).

My report source is as follows
SELECT
.age,
.bal FROM
;

The rest of the report are basically these two statements repeated about 20
times with a few variations:
=Count(IIf(([age] Between 18 And 29) And ([bal] Between 0 And
500),[age],Null))
=Sum(IIf(([age] Between 18 And 29) And ([bal] Between 0 And 500),[bal],0))

I can run the report and I get the data I expect but I get 20000+ identical
copies of it.
My margins look fine so I don't think there is any problem with that.

Any ideas or suggestions on where to look?
 
G

Guest

Hi Solag,

Put all your counting/grouping etc into a query that returns a single record
with teh counts you are after, then use that query to print the report,
rather than attempting to do the summing/counting etc on the report.

You get so many pages because the report will have one for every record
returned by your query - this behaviour is by design.

Damian.
 
G

Guest

Doing a little testing now, but it looks like it might work.

Thanks

Damian S said:
Hi Solag,

Put all your counting/grouping etc into a query that returns a single record
with teh counts you are after, then use that query to print the report,
rather than attempting to do the summing/counting etc on the report.

You get so many pages because the report will have one for every record
returned by your query - this behaviour is by design.

Damian.

Solag said:
I built a report that is an analysis of the values in a table. I am counting
records based on one criteria and totaling based on another. I have got the
report working with the exception that I get a page printed for each record.
Seeing as the report is essentially a summary, I intend it to be giving one
or two pages instead of 22692 (one for each record in the table).

My report source is as follows
SELECT
.age,
.bal FROM
;

The rest of the report are basically these two statements repeated about 20
times with a few variations:
=Count(IIf(([age] Between 18 And 29) And ([bal] Between 0 And
500),[age],Null))
=Sum(IIf(([age] Between 18 And 29) And ([bal] Between 0 And 500),[bal],0))

I can run the report and I get the data I expect but I get 20000+ identical
copies of it.
My margins look fine so I don't think there is any problem with that.

Any ideas or suggestions on where to look?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top