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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Blue407
Frequent Visitor

Calculate re-occurances of employee name in a table, also filtering on only Windows devices

In PowerBi I have a table which is a export from Microsoft Entra of all devices that are in the database, device name, operating system, asigned user etc.

 

I have a forumla I have created which works ok to give me a column of how many devices each user name appears against:-

 

UserWindowsDevicesCount = calculate(
COUNTROWS(EntraDeviceReport),
ALLEXCEPT(EntraDeviceReport, EntraDeviceReport[Owners]))

 

I have realised its reporting all devices and not just Windows devices that I want for this report.

So I tried to add an additional filter, but its not working, it just gives a total number of Windows devices in the list and not per user (owner).

 

UserWindowsDevicesCount = calculate(
    COUNTROWS(EntraDeviceReport),
    FILTER(EntraDeviceReport,EntraDeviceReport[Operating System]="Windows"),
    ALLEXCEPT(EntraDeviceReport, EntraDeviceReport[Owners]))
 
Can anybody help?
 
Thanks in advance 🙂
1 ACCEPTED SOLUTION
rajendraongole1
Super User
Super User

Hi @Blue407 - We can directly add the filter in the measure, not require filter function again,  and modify your formula to count only the Windows devices per user

 

UserWindowsDevicesCount = CALCULATE(
COUNTROWS(EntraDeviceReport),
EntraDeviceReport[Operating System] = "Windows",
ALLEXCEPT(EntraDeviceReport, EntraDeviceReport[Owners])
)

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





View solution in original post

2 REPLIES 2
rajendraongole1
Super User
Super User

Hi @Blue407 - We can directly add the filter in the measure, not require filter function again,  and modify your formula to count only the Windows devices per user

 

UserWindowsDevicesCount = CALCULATE(
COUNTROWS(EntraDeviceReport),
EntraDeviceReport[Operating System] = "Windows",
ALLEXCEPT(EntraDeviceReport, EntraDeviceReport[Owners])
)

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





Thats perfect, thankyou for such a fast response 🙂 🙂

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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