When the Report Usage Metrics Report stops refreshing

Have you ever had a Usage Metrics Report just stop refreshing? At the bottom you’ll see a little message that tells you to check the credentials. But you don’t have access to the Usage Metrics Report dataset in the list of datasets in the workspace because it’s hidden! So even if you wanted to delete it and nicely ask it to start again, you can’t do it from the workspace. What can you do? Well, you can delete the Usage Metrics Report dataset with the Power BI Rest API.

First, start a Windows PowerShell session. Make sure that you have the Power BI cmdlets installed by running the following in an elevated PowerShell session:

Install-Module -Name MicrosoftPowerBIMgmt

Next, you will have to log in to Power BI, so run:

Login-PowerBI

To delete a dataset, you’ll need to know the id of the workspace it’s in and the id of the dataset itself. To get the id of the workspace is easy. Go to the workspace and then in the URL, it’s the long guid right after “powerbi.com/groups/”. With that copied, you can now find all of the datasets in the workspace, including that Usage Metrics Report one that is hiding from you. You can do that by running:

Invoke-PowerBIRestMethod -Url groups/yourlongguidfortheidofyourworkspace/datasets -Method Get

This will return a bunch of json with all of the details about all of the datasets in your workspace, including the id. Scroll through it until you find the one that says “name”:”Usage Metrics Report” and copy the id value for that dataset. Then run the following to delete it:

Invoke-PowerBIRestMethod -Url groups/yourlongguidfortheidofyourworkspace/datasets/yourlongguidfortheidofyourdataset -Method Delete

And that’s it! Now go back to your workspace and click the three dots next to one of your reports and choose “View usage metrics report” to get it running again.

5 thoughts on “When the Report Usage Metrics Report stops refreshing”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s