all groups > sql server reporting services > march 2005 >
You're in the

sql server reporting services

group:

Sliding start and end date parameters in pushed reports


Sliding start and end date parameters in pushed reports Kenny
3/3/2005 6:05:51 PM
sql server reporting services:
I have a report that every Monday at 1:00AM, should run a report for
the previous week (Mon-Sun). If it only had to run for the previous
week, I would just get the dates in the stored procedure using
getdate() and dateadd(). However, when the report is viewed on-demand,
I want the user to be able to specify any start and end date, so the
report must have StartDate and EndDate as parameters.

When setting up the subscription is there anyway to avoid entering
hard-coded dates? I know I can get around it with some trickery in the
stored proc (e.g.- checking to see if start and end date parameters are
null) but I'd rather not.

Much thanks for any help!
Re: Sliding start and end date parameters in pushed reports Douglas McDowell
3/3/2005 11:40:45 PM
Use default values for your StartDate and EndDate values but use "From
query"

--
Douglas McDowell
douglas@nospam.solidqualitylearning.com


[quoted text, click to view]

Re: Sliding start and end date parameters in pushed reports Kenny
3/4/2005 2:32:01 PM
Outstanding! Instead of using "from query", I decided to use an
expression and DateTime.Now. Thanks!
AddThis Social Bookmark Button