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
jitpbi
Post Patron
Post Patron

display faulty devices

Hi,

 

the below is the sample of my dataset and the visual based on this dataset:

 

DatetimeDeviceFaults
10/22/20 8:10 PMAhealthy
10/22/20 9:20 PMAbreakdown
10/22/20 10:10 PMAshutdown
10/22/20 11:05 PMAoverheating
10/22/20 8:45 PMAhealthy
10/22/20 8:50 PMAhealthy
10/22/20 8:10 PMBhealthy
10/22/20 9:20 PMBoverheating
10/22/20 10:10 PMBhealthy
10/22/20 11:05 PMBhealthy
10/22/20 8:45 PMBhealthy
10/22/20 8:50 PMBhealthy

 

jitpbi_1-1603369818273.png

 
 

Now, I need to display the devices name if the sum of faults % (breakdown+overheating+Shutdown) is more than 25% in the last 24 hours and it should be diplay on a separate visual like this:

 

"Device (A) is having more than 25% faults"

 

the device name should come dynamically, also, if mutiple devices have more than 25% faults at time then it should display all the devices name like: "Device (A,B,C.....) having more than 25% faults"

 

Please suggest how to achieve this.

 

Thanks

 

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @jitpbi ,

 

Try this:

Measure =
VAR t =
    SUMMARIZE (
        FILTER (
            ADDCOLUMNS (
                'Table',
                "GT_Count_Percent_",
                    CALCULATE (
                        COUNT ( 'Table'[Faults] ),
                        FILTER (
                            ALLSELECTED ( 'Table' ),
                            'Table'[Device] = EARLIER ( 'Table'[Device] )
                                && 'Table'[Faults] IN { "breakdown", "overheating", "Shutdown" }
                        )
                    )
                        / CALCULATE (
                            COUNT ( 'Table'[Faults] ),
                            FILTER (
                                ALLSELECTED ( 'Table' ),
                                'Table'[Device] = EARLIER ( 'Table'[Device] )
                            )
                        )
            ),
            [GT_Count_Percent_] > 0.25
        ),
        [Device]
    )
VAR Device_ =
    CONCATENATEX ( t, [Device], ", " )
RETURN
    SWITCH (
        COUNTROWS ( t ),
        0, "No device is having more than 25% faults.",
        1,
            "Device (" & Device_ & ") is having more than 25% faults.",
        "Device (" & Device_ & ") are having more than 25% faults."
    )

device.JPG

 

 

Best regards

Icey

 

If this post helps,then consider Accepting it as the solution to help other members find it faster.

View solution in original post

2 REPLIES 2
Icey
Community Support
Community Support

Hi @jitpbi ,

 

Try this:

Measure =
VAR t =
    SUMMARIZE (
        FILTER (
            ADDCOLUMNS (
                'Table',
                "GT_Count_Percent_",
                    CALCULATE (
                        COUNT ( 'Table'[Faults] ),
                        FILTER (
                            ALLSELECTED ( 'Table' ),
                            'Table'[Device] = EARLIER ( 'Table'[Device] )
                                && 'Table'[Faults] IN { "breakdown", "overheating", "Shutdown" }
                        )
                    )
                        / CALCULATE (
                            COUNT ( 'Table'[Faults] ),
                            FILTER (
                                ALLSELECTED ( 'Table' ),
                                'Table'[Device] = EARLIER ( 'Table'[Device] )
                            )
                        )
            ),
            [GT_Count_Percent_] > 0.25
        ),
        [Device]
    )
VAR Device_ =
    CONCATENATEX ( t, [Device], ", " )
RETURN
    SWITCH (
        COUNTROWS ( t ),
        0, "No device is having more than 25% faults.",
        1,
            "Device (" & Device_ & ") is having more than 25% faults.",
        "Device (" & Device_ & ") are having more than 25% faults."
    )

device.JPG

 

 

Best regards

Icey

 

If this post helps,then consider Accepting it as the solution to help other members find it faster.

amitchandak
Super User
Super User

@jitpbi , Try a measure like

concatenatex(filter(summarize(Table, Table[Device], "_1", divide(calculate(countrows(Table), filter(Table, [Faults] in {"breakdown","overheating","Shutdown"})),countrows(Table))),[_1] >.25),[Device])

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

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors
Top Kudoed Authors