December 28, 2015 at 12:12 pm
In an SSRS 2012 report, I want the user to be able to pick a date from the parameter called @requestedreceiveddate and have the default value set as todays date. This paramter is set to have a value of date/time.
The logic of the default value is the following: select cast(getdate() as date) as [Request Received Date] in a dataset called requestdate. and this works fine.
However when the user is able to select a requested received date from a list of values the calendar icon goes away and the drop down list values display date and time. I only want the date to be displayed. I am using the following sql:
SELECT DISTINCT personID, cast(value as date) as [Request Received Date],
FROM OPS.dbo.Customcustomer
wHERE attributeID = 2911
and personID = @personID
order by [Request Received Date]
Thus can you tell me how to have only a list of dates displayed in the dropdown list of dates that the user can select from?
December 29, 2015 at 4:41 am
You need to date twice once for the parameter value, as a date, and once for the parameter label as formatted text.
You can add another field to your dataset where you convert the date to text, i.e. CONVERT(VARCHAR, date, 103) and use this value in the parameter Label and the actual date in the parameters Value field.
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply