Forum Discussion
Last Refreshdate with Tabular Editor 2 in a model deployed to SSAS Tabular Server
I have created my first model and it works very well with Tables, Relationships and Measures. I can make a Live connection to both Power BI as well as Excel so I am happy.
But one feature that I really like but haven't been able to implement in this model is the Refresh date and time for when the data model was last processed.
I am familiar with how to do it in Power Query in Power BI but fail when trying to implement it through Tabular Editor for this SSAS model. Is there a way to use similar M-code as in Power BI? Or perhaps any other nice trick?
Thank you
The solution was way easier than I thought to begin with.
1. Just add a new calculated table
2. Select it and i the Expression Editor write:
ROW ( "Timestamp", FORMAT ( NOW (), "yyyy-mm-dd hh:mm:ss" ) )
And when you save the model the Timestamp will appear in the Calculated tabel and be updated along with the other data in the model when the SSAS cube is processed.
3 Replies
- lbendlinSuper User
But one feature that I really like but haven't been able to implement in this model is the Refresh date and time for when the data model was last processed.Note that this data point is largely meaningless. Instead, identify a data point in your actual data (for example latest order placement date) to judge the "freshness" of your data. Power BI will happily refresh your old stale data over and over again.
- nick1234Regular Visitor
It is very true that the usefulness of a Last refresh date/time depends on the underlying data source.
I intend to use this Last refresh with a data source that is live and it is a very relevant information for the user to know if the data is 10 minutes old or 2 hours old.
But many sources I do use have underlying sources that updates once per month, and even some once per year.
So I don't agree with that LastRefresh is largely meaningless.
- nick1234Regular Visitor
The solution was way easier than I thought to begin with.
1. Just add a new calculated table
2. Select it and i the Expression Editor write:
ROW ( "Timestamp", FORMAT ( NOW (), "yyyy-mm-dd hh:mm:ss" ) )
And when you save the model the Timestamp will appear in the Calculated tabel and be updated along with the other data in the model when the SSAS cube is processed.