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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Same report for different date ranges 1

Status
Not open for further replies.

Bennie47250

Programmer
Nov 8, 2001
515
US
Using a MS SQL database and Crystal version 14.0.4.738 RTM

We have a standard report on calls received. The report users like to receive the report for calls received that day, for the prior week and for the prior month.

Currently to accommodate their wishes, I have 3 versions of the report that are basically the same except for the date selection. The issue is whenever a change is made to the report, I need to change 3 reports.

Would it be possible to use the same report for the various date ranges? If yes, how? The few things I tried did not work.

Thanks
Bennie47250
 
Sure--add a string parameter {?TimePeriod} with the three options you mention as values: Today, Prior Week, Prior Month. Then set up the record selection formula like this:

(
(
{?TimePeriod} = "Today" and
<your currentday selection formula here>
) or
(
{?TimePeriod} = "Prior Week" and
<your prior week selection formula here>
) or
(
{?TimePeriod}="Prior Month" and
<Your prior month formula here>
)
)

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top