Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Poor Performance with Current date -1

Status
Not open for further replies.

Bennie47250

Programmer
Nov 8, 2001
515
US
Using Crystal version 7.0 with i-series (AS400) DB2 database files.

I have several reports that are running thru a 3rd party report scheduler (Cizer) and the reports are designed to pull data for orders entered for the current date. (mydayefield = CurrentDate )

Occasionally Cizer will fail prior to running the report for the current day so the next morning I have to run the reports manually. If I change the selection formula to Current date -1, (mydayefield = CurrentDate -1) the report takes about 9 minutes to run. However if I change the Set Print Date/Time to the previous days date, the report will run in 30 seconds or less.

Any thoughts as to why it takes so long to run with the Current date -1 formula and how to improve it?
 
Hi,
Just a guess, but since each record has to be tested to see if it meets the criteria and evaulation of a formula will take longer than just checking the value against a constant, it will take longer to run - how much depends on the # of records inviolved and (maybe) whether indexes get involved.





[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top