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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
abeiswinger
Helper I
Helper I

Use Quick Measure to show Percentage by Column?

When I use "show percentage" option, it shows overall instead of by month.  Can I use Quick Measure to show the percentage of "On-Time" data out of the total of On-Time + Past Target?

 

My data with counts of Inspections:Inspection Percentages 1.png

What Power BI does:

Inspection Percentages 2.png

 

But I want it to say January = 79%, February =84%, etc.

January = 30/38

February = 38/45

etc.

 

If it helps... my spreadsheet/datasource is something like this:

Column A = Inspection number (unique identifier, no repeating)
Column B = Date
Column C = On-Time or Past Target

 

I'm okay with removing "Past Target" and leaving it as blank, if that helps with a Quick Measure to count the On-Time out of the total... I just don't know which one to use.

 

Thanks

1 ACCEPTED SOLUTION
v-yuezhe-msft
Employee
Employee

@abeiswinger,

Right-click your table and select “New measure” to create the following measure in your tables.

Total = SUM(Table[Column A])
On-Time total = CALCULATE(SUM(Table[Column A]),FILTER(Table, Table[Column C]="On-Time"))
percent = [On-Time total]/[Total]

Then create line chart as follows.
1.JPG


Regards,

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yuezhe-msft
Employee
Employee

@abeiswinger,

Right-click your table and select “New measure” to create the following measure in your tables.

Total = SUM(Table[Column A])
On-Time total = CALCULATE(SUM(Table[Column A]),FILTER(Table, Table[Column C]="On-Time"))
percent = [On-Time total]/[Total]

Then create line chart as follows.
1.JPG


Regards,

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-yuezhe-msft

 

I receive an error that says "The syntax for "On" is incorrect.  Whatever I put instead of "On-Time Total" gives the same mesage (the syntax for ____ is incorrect)

@abeiswinger,

Please share sample data of your table, and post the screenshot of your scenario. And you can check my DAX in the attached PBIX file.

Regards,

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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