Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
JIblasco
Helper I
Helper I

Design a DBA Dashboard

Hi,

 

I'm trying to design a Dashboard to control the activity/errors/issues related to our databases. For this purpose, I have created a very easy table with only three columns. KPI, value and timestamp. My target is to create a simple panel (maybe with tarjet cards) that shows the last value of each KPI.

 

AS you can see, I'm saving in my table historical information, but I only want to show the las timestamp row of each KPI (marked in bold).

 

KPI Valuetimestamp
Average CPU time10%2020-08-20 09:20
Average CPU time12%2020-08-20 09:22
Average CPU time2%2020-08-20 09:24
Free Memory70%2020-08-20 09:21
Free Memory75%2020-08-20 09:22
Free Memory10%2020-08-20 09:24

 

Honestly, I have tried but I haven't found the way to do it. ¿Could you please help me?

 

Thanks in advance.

2 ACCEPTED SOLUTIONS
Greg_Deckler
Community Champion
Community Champion

@JIblasco - You can create a selector for this

Selection selector for selection options

VAR __Max MAXX (ALL('Table'),[timestamp])

Return

IF(MAX('Table'[timestamp]) at __Max,1,0)

See Complex Selector - https://community.powerbi.com/t5/Quick-Measures-Gallery/The-Complex-Selector/m-p/1116633#M534

Also, maybe Lookup Min/Max - https://community.powerbi.com/t5/Quick-Measures-Gallery/Lookup-Min-Max/m-p/985814#M434



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

v-easonf-msft
Community Support
Community Support

Hi , @JIblasco 

As mentioned by @amitchandak  ,please create a calculated column:

Rank = RANKX(FILTER(ALL('Table'),'Table'[KPI ]=EARLIER('Table'[KPI ])),'Table'[timestamp],,DESC)

 And applied it to filter pane:

206.png

 

Best Regards,
Community Support Team _ Eason

View solution in original post

4 REPLIES 4
v-easonf-msft
Community Support
Community Support

Hi , @JIblasco 

As mentioned by @amitchandak  ,please create a calculated column:

Rank = RANKX(FILTER(ALL('Table'),'Table'[KPI ]=EARLIER('Table'[KPI ])),'Table'[timestamp],,DESC)

 And applied it to filter pane:

206.png

 

Best Regards,
Community Support Team _ Eason

amitchandak
Super User
Super User

@JIblasco , Take these two measures along with KPI in you visual

new timestamp = lastnonblank(table[timestamp],blank())
new Value = lastnonblankvalue(table[timestamp],max(Table[Value]))

 

Or create a Rank of time inside KPI and filter on 1

For Rank Refer these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/3...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi,

 

Thank you for your quick response. I have decided to create a view in the database with the las timestamp of each KPI. Anyway, thank you for the rank refers.

 

 

Greg_Deckler
Community Champion
Community Champion

@JIblasco - You can create a selector for this

Selection selector for selection options

VAR __Max MAXX (ALL('Table'),[timestamp])

Return

IF(MAX('Table'[timestamp]) at __Max,1,0)

See Complex Selector - https://community.powerbi.com/t5/Quick-Measures-Gallery/The-Complex-Selector/m-p/1116633#M534

Also, maybe Lookup Min/Max - https://community.powerbi.com/t5/Quick-Measures-Gallery/Lookup-Min-Max/m-p/985814#M434



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.