Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Analysis Server and Reporting Services (2005)
 Displaying @startdate and @enddate in report

Author  Topic 

stevenc49
Starting Member

14 Posts

Posted - 2008-07-17 : 19:52:25
Hi, I have a report that takes input @startdate and @enddate and generates data depending on those fields
(using the line: WHERE created BETWEEN @startdate AND @enddate )

Is there an expression that will display exactly value I have entered for @startdate and @enddate?

I tried:
=First(Fields!@startdate.Value)
and
=First(Fields!@enddate.Value)

but sql won't render it.

Thanks in advance

dexter.knudson
Constraint Violating Yak Guru

260 Posts

Posted - 2008-07-17 : 21:13:48
You need to convert the format from datetime to a string: CStr(Fields!@enddate.Value)
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-07-18 : 05:41:30
Have you set parameters in report for start and end date? if yes, use
Parameters!StartDate.value and Parameters!EndDate.value
Go to Top of Page

dexter.knudson
Constraint Violating Yak Guru

260 Posts

Posted - 2008-07-18 : 07:19:55
Good point!
Go to Top of Page

stevenc49
Starting Member

14 Posts

Posted - 2008-07-18 : 14:58:24
Thanks guys. Both way works.
Go to Top of Page
   

- Advertisement -