cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
MarkJames Member
Member

Usage Metric Report - Custom Measure for Distinct Date and Report by User

Hi,

 

I'm connecting to the Usage Metric Report in my workspace via Power BI Desktop - I've saved the Usage Metric Report after viewing the report in the Workspace which then let's me connect to it as a datasource in Power BI Desktop. I'm doing this because I want to add in some additional measures that help make the report more usable for me.

 

In my workspace I have 3 reports. If one use views all 3 reports in one day I want this to total 3, regardless of the number of times each report is viewed in that day. Then I want to be able to roll this up across days and users.

 

At the moment the 2 standard count metrics don't give me what I'm looking for:

 

  • ViewsCount - this counts the number of pages in a report that were viewed. I only want to count if the report was viewed, not all it's pages
  • ViewersCout - this only give me the unique number of users

 

I'm able to get the total distinct days viewed by user using the following:

 

Viewed = CALCULATE(DISTINCTCOUNT(Views[Date]),GROUPBY(Users,Users[UserGuid]))
 
But this only gives me the days. If they've viewed more than one report in that day it doesn't count this. Below I've given a screenshot of the table of data to help illustrate what I'm trying to achieve:
 
Usage Metric.PNG
In this example you'll see a column for Date (from Views table) and ReportGuid (from Views table) with the names of 3 Users (from Users table) in columns and a count of the times each report has been viewed, using the DAX calculation above. The totals are the bottom are only counting the unique days, not the unique days and report IDs. The real figures should be 1, 7 and 11.
 
Any suggestions?

MarkJames

1 ACCEPTED SOLUTION

Accepted Solutions
MarkJames Member
Member

Re: Usage Metric Report - Custom Measure for Distinct Date and Report by User

I figured it out:
 
ReportViews = COUNTROWS(SUMMARIZE(Views,Views[Date],Views[ReportGuid],Users[FamilyName]))

View solution in original post

1 REPLY 1
MarkJames Member
Member

Re: Usage Metric Report - Custom Measure for Distinct Date and Report by User

I figured it out:
 
ReportViews = COUNTROWS(SUMMARIZE(Views,Views[Date],Views[ReportGuid],Users[FamilyName]))

View solution in original post

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 121 members 1,585 guests
Please welcome our newest community members: