Forum Discussion
Wrong data from Google Analytics
Hi Xiaoxin,
Thank you for your feedback.
However i think it may not be related to api delay. If that's a delay issue, only data of past (few) days will have impact, right? When I compare the data downloaded from the G.A Web to the data generated via Power BI Desktop for a long period of time (more than one year), none of the data matches.
| = Cube.Transform(#"xxxxxxxx", |
| { |
| {Cube.AddAndExpandDimensionColumn, "ga:date", {"ga:date"}, {"Date"}}, |
| {Cube.AddMeasureColumn, "New Users", "ga:newUsers"}, |
| {Cube.AddMeasureColumn, "Users", "ga:users"} |
| }) |
The above is the code generated from "Add item" step in Power BI Desektop.
Any idea?
Appreciate feedback.
Regards,
Hi MF_Wong,
I just figured this out today.
The reason the numbers do not match is due to the sampling limit from google.
Here is what I did and worked:
1- Go to your Query Editor and filter your report using your date field.
2- Add a custom filter (do not use "Equals..., Before..., After... so on, custome is the only way to prevent sampling).
3- Within the custom filter then you can set your filter. I did a range: "is after and equal and is before and equal". I then compared to the same time period on Google Analytics and my data matched!
With the custom filter you are filtering within the cube and not locally on your powerbi desktop so you are able to work around sampling.
Hope this helps,
- KellyDittmar8 years agoAdvocate IV
fmatioli06 - I am also having this issue and want to make sure I'm with you. Are you applying your date filter here? Or somewhere else?
- fmatioli068 years agoFrequent Visitor
Yes, using the custom filter option under the date field. Your screenshot is correct.
I have been using it now anytime I connect directly to GA.
- KellyDittmar8 years agoAdvocate IV
fmatioli06 - You are brilliant! That solved my problem. Thank you so much for the solution! It just made me into a hero. What a great way to end a week!
Kelly