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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
jlie
Advocate I
Advocate I

Power BI Desktop returning complete non-sense from Google Analytics

Hey all,

 

I cant seem to get the Google Analytics Connector in Power BI Desktop to work properly. Especially when I query custom dimensions, the data is completely messed up and not accurate at all (I mean not even remotely accurate; e.g. the query explorer or GA Webpage returns 500 rows, PowerBI returns 100 or sometimes even below 20 rows).

 

I can not figure out what I am doing wrong - I am a 100% certain that I query the right GA account, the right property and the correct view. I am also 100% certain and even quadruple-checked that I have no filters active and definitely check the correct dimensions & metrics.

 

Do you have any idea, why BI Desktop returns completely different und incomplete data, while Query Explorer and GA Web do return the exact and (apparently) correct data? Is there anything I miss? Because as far as I can reproduce, the issue only emerges when querying custom dimensions.

 

Best Regards,

Jannis

1 ACCEPTED SOLUTION
jlie
Advocate I
Advocate I

Ok, i figured out what caused the problem: It was, sampling.

 

What led to the behavior:

I had a query that did not need any date and therefore I did not add the date as a dimension. However, this led to sampling (I did not see this with Query Explorer, since I am forced to add a date filter there). 

 

How to solve it:

If anybody ever searches this, here's the solution: Add the date dimension and make sure, that this is the very first attribute, that you are filtering on in the Query Editor. Choose a filter date is befor / after / in between and not in the next / in the last, because otherwise Power BI will not alter the Query and will still receive sampled data. This applies also, if the first Filter is not a Date Filter but maybe a pagepath or a custom dimension.

 

On the other hand this confirms that PowerBI indeed queries only the date-ranges that are selected through a filter. However, this is a very, very bad User Experience and far away from "intuitive". Please change this behavior this or at least document this in a feasible way.

View solution in original post

4 REPLIES 4
jlie
Advocate I
Advocate I

Ok, i figured out what caused the problem: It was, sampling.

 

What led to the behavior:

I had a query that did not need any date and therefore I did not add the date as a dimension. However, this led to sampling (I did not see this with Query Explorer, since I am forced to add a date filter there). 

 

How to solve it:

If anybody ever searches this, here's the solution: Add the date dimension and make sure, that this is the very first attribute, that you are filtering on in the Query Editor. Choose a filter date is befor / after / in between and not in the next / in the last, because otherwise Power BI will not alter the Query and will still receive sampled data. This applies also, if the first Filter is not a Date Filter but maybe a pagepath or a custom dimension.

 

On the other hand this confirms that PowerBI indeed queries only the date-ranges that are selected through a filter. However, this is a very, very bad User Experience and far away from "intuitive". Please change this behavior this or at least document this in a feasible way.

I have added date dimension as the first column, but still i get wrong results 😞

@shzyincu you still need to filter on the date dimension. Set a filter for one specific date and compare the results with your online report or a result from Google Query Explorer.

 

In the meantime, I figured out that the behavior is called "query folding" and very well documented for SQL data sources and not-at-all documented for Websources (Google Analytics, Salesforce, etc)

@jlie i have already tried many different ways to achive the correct result but in vain 😞 this is very bad from Microsoft, how come they market such thing if it has flaws 😞

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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