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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
drew61199
Frequent Visitor

Count of days with measurement under certain percentage

I'll preface by saying I'm new to DAX / PBI. I have two fields - "possible" and "actual" - for multiple machines and also daily data for each. I created a new measure to create a utilization percentage. I need to count the instances where this is less than 65%, but cannot figure it out. As an example of what I'm trying to achieve:

 

  1. Machine A - Mon 80%, Tues 80%, Wed 80%
  2. Machine B - M 50%, T 50%, W 60%
  3. Machine C - M 70%, T 45%, W 85%

I would expect to get 4 in this example. My dataset is signifcantly larger, but I'm way low on my figures. I assume b/c I'm only counting days and not days AND machines?! If so....how do I alter my formula correctly? 

 

_Utilization=DIVIDE(SUM('PowerBI_DATA'[Actual]), SUM('PowerBI_DATA'[Possible]))
 
_Under_Utilized=CALCULATE(COUNT(PowerBI_DATA[Date]),FILTER('Facility Data',[_Utilization] < .65))
1 ACCEPTED SOLUTION

@drew61199 

Ok please try

_Under_Utilized =
SUMX (
    SUMMARIZE (
        TableName,
        TableName[Date],
        TableName[Machine ID],
        TableName[Area],
        TableName[District],
        TableName[Facility]
    ),
    CALCULATE ( IF ( [_Utilization] < 0.65, 1 ) )
)

View solution in original post

8 REPLIES 8
tamerj1
Super User
Super User

@drew61199 

However, please try

_Under_Utilized =
SUMX (
    CROSSJOIN ( VALUES ( 'Date'[Date] ), VALUES ( TableName[Machine ID] ) ),
    CALCULATE ( IF ( [_Utilization] < 0.65, 1 ) )
)
tamerj1
Super User
Super User

@drew61199 

Would you please share a screenshot of your visual hiding any sensitive data? I guess the count will be displayed in a card visual?

I'm just building it out, but yes, as a test, I'm using it in a card. I will later utilize in barcharts, etc to showcase top opportunities (based on lowest utilization). I'm comparing my figures to the QLIK visual I have that PBI is replacing, but I've drilled to individual items and a small subset of the data (single week) and verified the formula above is not accurate

@drew61199 

Sorry I think I was not clear in my question. 
The utilization value that you are trying to count is based on machine/date? Are we talking about daily basis? And do you have a date table? If not please clarify. Thank you

@drew61199 

Thank you for clarification. What are you slicing by when using the [_Utilization] measure?

The date comes in with the data feed. Multiple columns - physical location hierarchy (Area, District, Facility), Date, Machine ID, and aforementioned actual / possible throughput. I will be slicing by the hierarchy to show top opportunity Area, District, Facility, Machine ID

@drew61199 

Ok please try

_Under_Utilized =
SUMX (
    SUMMARIZE (
        TableName,
        TableName[Date],
        TableName[Machine ID],
        TableName[Area],
        TableName[District],
        TableName[Facility]
    ),
    CALCULATE ( IF ( [_Utilization] < 0.65, 1 ) )
)

Sorry for delayed response....had some vacation days.

It seemed to result in too high of a number when I had all of the hierarchy levels summarized, but worked great with simply the date and machine ID.

Thank you so much! 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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