Not long ago a SCCM Administrator, that I was mentoring, was asked by his Manager to create a weekly status report on their upgrade from Windows 7 to Windows 10. The admin did a great job putting together a dashboard and associated drill-through reports, but he forgot to include the execution date details. Below I’ll explain why inserting the execution date into a report is very important and how you can add it to all of your reports.
As I said, this Admin did a great job! Everyone loved his reports because they showed exactly what they wanted to see. This report set was eventually forwarded up the chain of command. One day the CTO took a look at a copy of these reports and asked when they were created. Here’s the problem: no one could say for certain when. Why did the CTO care about when the reports were created? Well, he wanted to compare the results over time. The numbers in any report will fluctuate from week to week, but without knowing when a particular report was created there was no way to compare them.
Back the request came to the SCCM administrator to determine when each report in the set was executed, so I was asked to help with figuring out when these reports were produced.
In the end we couldn’t say for certain when each report was created, but we could give it our “best” guess. Obviously this didn’t make the CTO incredibly happy, but our next response did. We told the CTO that we could solve this problem moving forward. The date would be added to each dashboard and report, and never again would someone have to guess when a report was produced.
How was the execution date added? There is a default SSRS variable that lists the date and time of when a report is executed. If you’d like to be proactive and add this information to all of your reports then continue reading.
Tip for Automating Report Updates
If you don’t want to be troubled with creating a new report with the latest details every week, you can automatically update the status of reports. In this case, the Admin created a Windows file share subscription (please see How to Set-up a Windows File Share Subscription for more information) where the older report was over-written each Monday morning. He was also tasked with creating a PDF version of this weekly report which would be kept with the company’s project records. Using the Windows file subscription was great because it solved the problem of record keeping.
How to Add the Execution Date to a Report
In order to add the date and time of when a report is created, you need to start by adding a text box in the footer area. For more information about how to add a footer, please see my blog post, How to Spruce-up Your SCCM Reports by Adding Page Numbers.
Right-click on the text box and select Expression… Alternatively, you can also access the expression dialog area from the text box properties window, but that involves a few more steps.
In the expression text box, paste one of the two expressions listed below. Lastly, click on the OK button.
Execution Date Expression #1
Use the expression listed below the screenshot if you’d like to show the date without the time. Personally, I like to use the text, “Printed on,” but you can use whatever you like such as, “Produced on,“ or “Cynhyrchwyd ar,“ for my Welsh friends or, “Toodetud,“ for my Estonian friends. Make sure, though, to add a space between the text and the date.
=“Printed on “ & Today
Execution Date Expression #2
The expression below this screenshot will show the date and time.
=“Printed on “ & Globals!ExecutionTime
I hope this post demonstrates how adding the execution date to a report is helpful. This is one of those little things that I always tell people should be included within all dashboards and reports. No one will ever have to ask again when the report was created.
If you have any questions about how to add the execution date to a report, please feel free to contact me @GarthMJ.