Answered by:
Data Type on report is different than Data Source

Question
-
Hi Everyone
i have createad a simple daily status report using SQL Server 2008R2 DB & SSRS. My data source is simple table which has one column & its datatype is date. But when i pull this column on report in preview it shows date & time.
i just want to show the date not time. So can you please help me with this.
thank you in advance
- Edited by Rhythm Devine Tuesday, March 4, 2014 10:13 AM
Tuesday, March 4, 2014 10:12 AM
Answers
-
Hello Rhythm,
can you try this.
=FormatDateTime(your field datacolumn , DateFormat.ShortDate)
replace the data expression in report with above expression.
put your data field column at place of bold place.
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:35 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:13 AM -
you can apply format function to show just the date
ie like below
FormatDateTime(Fields!DateField.Value,2) or Format(Fields!DateField.Value,”dd/MM/yyyy”) etc
depending on what format you wantPlease Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:36 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:15 AM -
Hi,
You can also try like this ,
=FormatDateTime(Now, DateFormat.ShortDate) =CDate(Now).ToString("dd/MM/yyyy")
Also try this link - http://thavash.wordpress.com/2007/04/10/working-with-dates-in-reporting-services/sathya - www.allaboutmssql.com ** Mark as answered if my post solved your problem and Vote as helpful if my post was useful **.
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:37 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:35 AM
All replies
-
Hello Rhythm,
can you try this.
=FormatDateTime(your field datacolumn , DateFormat.ShortDate)
replace the data expression in report with above expression.
put your data field column at place of bold place.
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:35 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:13 AM -
you can apply format function to show just the date
ie like below
FormatDateTime(Fields!DateField.Value,2) or Format(Fields!DateField.Value,”dd/MM/yyyy”) etc
depending on what format you wantPlease Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:36 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:15 AM -
Hi,
You can also try like this ,
=FormatDateTime(Now, DateFormat.ShortDate) =CDate(Now).ToString("dd/MM/yyyy")
Also try this link - http://thavash.wordpress.com/2007/04/10/working-with-dates-in-reporting-services/sathya - www.allaboutmssql.com ** Mark as answered if my post solved your problem and Vote as helpful if my post was useful **.
- Proposed as answer by Katherine Xiong Wednesday, March 5, 2014 3:37 AM
- Marked as answer by Katherine Xiong Tuesday, March 11, 2014 12:33 PM
Tuesday, March 4, 2014 11:35 AM