Click here to monitor SSC
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in
Home       Members    Calendar    Who's On

Add to briefcase

Scheduling a reprot to pull quarterly data Expand / Collapse
Posted Tuesday, May 14, 2013 9:35 AM


Group: General Forum Members
Last Login: Thursday, May 30, 2013 7:52 AM
Points: 17, Visits: 102
I have a report that pulls monthly data based on begin date(parm1) and end date(parm2)
I would like to schedule it to pull data on a quarterly basis... April, July, Oct, and Dec.

I have created the following Expression for parm1:

=iif(DatePart("m",Parameters!parm1.Value)<=3, "Firstquarter",
iif(DatePart("m",Parameters!parm1.Value)>3 and (DatePart("m",Parameters!parm1.Value)<=6, "Secondquarter",
iif(DatePart("m",Parameters!parm1.Value)>6 and (DatePart("m",Parameters!parm1.Value)<=9, "Thirdquarter",
iif(DatePart("m",Parameters!parm1.Value)>9 and (DatePart("m",Parameters!parm1.Value)<=12,"Fourthquarter",

The error I receive is:
A Value expression used for the report parameter ‘parm1’ refers to a field. Fields cannot be used in report parameter expressions

Any Ideas to get this to work??

Post #1452678
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse