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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
mikelee1701
Helper III
Helper III

KPI card to Just show (specific) top value from a calculated table.

Hi All,

 

I hope this is an easy question.  I am using some complicated measures (and sorting) to get exactly what I want, so I hope it is not because of that is is preventing me to use the KPI Visual correctly.

 

1) I would like my current KPI to look something like

correctkpi.jpg

It has the current values (in green) and it is comparing to prior values to give me the percentage increase/decrease from the prior period.

 

2) I have a table that is has the exactly what I want to display using JUST the first row (using a combination of calculated columns and sorting of the highest values for "current values" column:

fullsorted.jpg

 

3) BUT, As you know if I convert the table visual to KPI card it will not give me just the first row because there are rows of data:

badkpia.jpg

 

4) So what I did in order to just display the first row to get the KPI to somewhat work is use filters:

filterN.jpg

5) and I get this:

betterkpi.jpg

which is better, but the percentage is off.  

 

6) That's because It seems that when I filter to topN, it defaults to first value of the calculated column for the "PrevD2Dval" column which is NOT the value I want (I want 49,189,334):

wrongprev.jpg

 

Question:

How can I make my KPI to use just the first rows of values that I've set up (in step 2) so that I get the correct KPI valus and percentage?

 

Thank you all in advanced.

Mike

6 REPLIES 6
v-xiaotang
Community Support
Community Support

Hi @mikelee1701 

Could you share a sample file? you can replace raw data with bogus data to protect your privacy. I will check it later. Besides, if changing the settings still doesn't make the Card visual display the value correctly, then I'm afraid I'll have to create a measure.

 

Best Regards,

Community Support Team _Tang

If this post helps, please consider Accept it as the solution to help the other members find it more quickly.

@v-xiaotang ,

Here is my sample file.

Thank you!

 

https://1drv.ms/u/s!AnihqWkZVs-F3Z9dn-yfuOiPLCkKfA?e=FmdUUf 

 

Thanks,

Mike

I will work on stripping my file from all sensitive info.  it's also connected to an Oracle DB.

Thanks in Advanced.

 

BTW.  Is it wrong to just use a table then cover it up with blank text boxes so just the single top column of a row just displays that one number?  Is this a bad practice?

parry2k
Super User
Super User

@mikelee1701 and check out this video I have on KPI card visual Make your Time Intelligence KPIs SMART - Power BI - YouTube

 

 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

parry2k
Super User
Super User

@mikelee1701 The reason your KPI card doesn't show the value in the first place is that it is going to the last date in your table, if you can apply a filter on the KPI card for the date with the latest data it will work. To simply test it, first filter your KPI card visual for Dec 13, 2021, and see if you get the correct results.

 

 

Follow us on LinkedIn and YouTube.gif to our YouTube channel

 

Learn about conditional formatting at Microsoft Reactor

My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would  Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!

 

Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

@parry2k ,

I'm afraid that does not work either.  I filter to 12-13-21 and I get point #6 (36,538,664).

 

It has to do with my calculated column "PrevD2Dval" in which I applied this similar method with slicers:

https://community.powerbi.com/t5/Desktop/Comparing-two-dynamic-time-span-Values-in-Power-BI/m-p/1190...

 

I think is is because i am filtering out the rows from which the measure is using to create my rows for each day.  Question is how to do that without a table.?

 

I am comparing two values from different time periods, the second column "PrevD2Dval" is my prior data from which I am comparing the "current values" with.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.

Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.