How do I display todays date on SSRS report?
Asked Answered
Z

10

20

I want to show up Todays date as report generated date on SSRS report.

How can i do that ?

should I use any variable ?

please help me I'm newbie to SSRS.

For example refer this image: enter image description here

Zook answered 11/4, 2013 at 4:43 Comment(0)
L
27

date column 1:

=formatdatetime(today)
Legislation answered 11/4, 2013 at 4:45 Comment(3)
where i need to put this expression exactly... sorry to ask i'm new to ssrsZook
For instance in Textbox. (Add textbox to your report from report items list, then right click on the added textbox and choose expression).Scaramouch
if you wish to format your date you can use =format((today),"dd/MM/yyyy")Bleed
G
18

Try this:

=FORMAT(Cdate(today), "dd-MM-yyyy")

or

=FORMAT(Cdate(today), "MM-dd-yyyy")

or

=FORMAT(Cdate(today), "yyyy-MM-dd")

or

=Report Generation Date: " & FORMAT(Cdate(today), "dd-MM-yyyy")

You should format the date in the same format your customer (internal or external) wants to see the date. For example In one of my servers it is running on American date format (MM-dd-yyyy) and on my reports I must ensure the dates displayed are European (yyyy-MM-dd).

Goat answered 16/12, 2014 at 10:45 Comment(0)
S
11

You can also drag and drop "Execution Time" item from Built-in Fields list.

Scaramouch answered 11/4, 2013 at 8:31 Comment(0)
C
11

to display date and time, try this:

=Format(Now(), "dd/MM/yyyy hh:mm tt")
Cheapjack answered 8/12, 2015 at 2:11 Comment(0)
E
4

You can place a text-box to the report and add an expression with the following value in it:

="Report generation date:  " & Format(Globals!ExecutionTime,"dd/MM/yyyy  h:mm:ss tt" )
Evanston answered 17/7, 2017 at 1:47 Comment(0)
K
3

In the text box that contains the header, you can use an expression to get the date. Try something like

    ="Report Generation Date: " & Today()

right click in the text box in the layout view. At the bottom of the list you'll see the expression option. There you will be able to enter the code. This option will allow you to avoid adding a second textbox.

Kast answered 15/4, 2013 at 1:32 Comment(0)
C
2

Just simple use

=Format(today(), "dd/MM/yyyy")

will solve your problem.

Chimney answered 4/7, 2017 at 19:4 Comment(0)
E
1

you may use the build-in function

Globals!ExecutionTime
Eskew answered 11/12, 2022 at 4:9 Comment(0)
G
0
  1. Inset Test box in the design area of the SSRS report.
  2. Right-click on the Textbox and scroll down and click on the Expression tab
  3. just type the given expression in the expression area: =format(Today,"dd/MM/yyyy")
Gilley answered 17/1, 2018 at 11:43 Comment(0)
D
0

You can use built in function =Globals!ExecutionTime and make the value = [&ExecutionTime] (or whatever you want to call it)

You can also add the user Id of the person generating the report using the built in function

=User!UserID

Dulcine answered 10/1, 2023 at 9:42 Comment(1)
Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.Writer

© 2022 - 2025 — McMap. All rights reserved.