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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
vincenttys
Frequent Visitor

Measure help

Hi all,

I have a data as below and column highlighted in yellow is a calculated column based on Entry Time Deviation and Exit time Deviation. I want to use this data and generate report similar to the following table. With Entry Time Deviation along, there are 18 different measure if i would go and create measure one at a time. Is there a better way to do this?

 

Data

Data.PNG

 

Report

Report.PNG

 

Thank you

 

Regards,

Vince

3 REPLIES 3
datawailor
Advocate II
Advocate II

May be a little challenging to explain but ideally, you do this in power query by 

  1. Reference the table to create a seperate table we'll use to set somethings up
  2. create a list of all the entry and exit time variance values (entry time variance <15, entry time variance -15 to 0, etc)
  3. Add a column that concatenates "% " to each entry
  4. Add an index to the lis
  5. Select the Index column created and unpivot on the other columns
  6. Add a column that enables you distinguish between values and %ages. Something like if left(Label,1) = "%" then "%age" else "value"
  7. Add another column that groups your values into Entry time deviation and Exit time deviation using a similar method as the previous step

Once the you have the table, you can close and join the field to the main table with the data and do the rest with DAX. Things like this are typically best done with Power query and am sure im missing a smnall step but you get the idea. if i have time i could buiold it out

 Hi @datawailor 

 

I have a go and i think i can create a separate table but not sure how to join it back to the main table with data. Can you please assist?

 

Thank you

Thanks for the recommendation. I will have a go. 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

Find out what's new and trending in the Fabric Community.

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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