Print Page | Close Window

Total Page Count

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=19204
Printed Date: 01 May 2024 at 7:44pm


Topic: Total Page Count
Posted By: Jonart
Subject: Total Page Count
Date Posted: 02 Mar 2013 at 7:31pm
I have a report that requires seven hours to run. I would like to shorten the runtime. When the report is running I noticed the message which appears at the bottom left corner of the screen. It seems to indicate what type of operation Crystal is doing: Reading Records, Subreport, Accessing Database, Determining Total Page Count. It is this last message that interests me, as it seems to appear each time Crystal reads and processes a record. The report should run faster if I could eliminate whatever is causing Crystal to Determine Total Page Count. I realized that some text objects in the page header contained conditional suppression formulas in the form of

If PageNumber = TotalPageCount ...

I commented out those formulas and reran the report. But it does not seem faster and the message Determining Total Page Count still flashes.

Do all reports need to determine the page count even if there are no formulas that include this function? Does this affect runtime?



Replies:
Posted By: Sastry
Date Posted: 03 Mar 2013 at 9:42pm
HI

Check whether you have 'Page N of M' placed on the report. Also you need to check 'Total Page Count' is used in any other formulas or it was placed in the report.



-------------
Thanks,
Sastry


Posted By: hilfy
Date Posted: 04 Mar 2013 at 3:54am
If you have Page N of M or Total Page Count anywhere in the report, Crystal has to physically render every page while it's generating the report.  This can cause significant speed issues.  I recommend that you replace "If PageNumber = TotalPageCount..." with something like "If OnLastRecord..."
 
-Dell


-------------
Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics


Posted By: Jonart
Date Posted: 04 Mar 2013 at 4:36am
Yes, my report does have Page n of m. I will remove that and try again.

Thank you Sastry and Dell


Posted By: Jonart
Date Posted: 04 Mar 2013 at 5:35am
That simple change doubled the speed.

Thanks!
Jonart


Posted By: Jonart
Date Posted: 04 Mar 2013 at 8:25am
Originally posted by hilfy



I recommend that you replace "If PageNumber = TotalPageCount..." with something like "If OnLastRecord..."
 
-Dell


OnLastRecord also worked perfectly for the conditional suppression.

Jonart



Print Page | Close Window