I have a SQL query: select ModifiedDate from Person.Person
and this returns the date as 2/24/1998 12:00:00 AM
I'm trying to display this in MM/dd/yyyy
format in SSRS report. I have used the expression =Format(Fields!ModifiedDate.Value,"MM/dd/yyyy")
But, still it's coming as 2/24/1998 12:00:00 AM
I want to display this as 2/24/1998
.
How can I do this?
Right click - properties on the cell, select format, click the ellipsis "...", and you can see the date formats from there. This will be converted into a date code when you OK the dialog.
I would recommend using the format codes:
Right click - properties on the cell, select format, click the ellipsis "...", and you can see the date formats from there. This will be converted into a date code when you OK the dialog. This is useful as it sets the date in the fomat the user wants to see it in.
To convert the data within SSRS and not the data source you could try using something like:
=Format(Cdate(Fields!ModifiedDate.Value),"dd/MM/yyyy")
Another sample for you without Cdate:
=Format(Fields!ModifiedDate.Value,"dd/MM/yyyy")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With