hi...
i need help from u all...
i have a problem about SSRS 2005..
the problem is;
i have to default start date to "01/01/year"
any ideas how to get the current year?...my end date is key in by
user...
i have try this
=cdate("01/01"+cstr(parameter!endDate.value ))
but it not works.. :(
that's all...
thanks for any advance..Create a sql query against a sql database, either the database you use for
your report or just the ReportServer database
Create a query like this:
select DATEADD(yy, DATEDIFF(yy,0,getdate()), 0) as FirstDayOfYearIn your
parameter section, use FirstDayOfYear as default valueTo calculate the first
date of a year if the user changes the yearselect DATEADD(yy, DATEDIFF(yy,0,
convert(datetime, @.EndDate, 104), 0)(You might have to change the
"convert(datetime, @.EndDate, 104)" part to make it work with your datetime
format etc.More "Examples of how to Calculate Different SQL Server Dates"
at:http://www.databasejournal.com/features/mssql/article.php/3076421Kaisa M.
Lindahl Lervik
"!m@.pe@.ce" <imapeace@.gmail.com> wrote in message
news:1159430326.495358.138230@.e3g2000cwe.googlegroups.com...
> hi...
> i need help from u all...
> i have a problem about SSRS 2005..
> the problem is;
> i have to default start date to "01/01/year"
> any ideas how to get the current year?...my end date is key in by
> user...
> i have try this
> =cdate("01/01"+cstr(parameter!endDate.value ))
> but it not works.. :(
> that's all...
> thanks for any advance..
>
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment