AbdFatah / analytics-issues

Automatically exported from code.google.com/p/analytics-issues
0 stars 0 forks source link

Can't retrieve correct analytics data for each day #220

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Name of affected component: Core Reporting API

Name of related library and version: google-api-php-client 0.5.0

Issue summary:
I'm creating an analytics custom data report page, and the problem is that when 
I try to limit the dates (start and end dates) I get wrong values. The problem 
appears when I set the start and end dates in different months (for example: 
from 2012-05-23 to 2012-06-25), it looks like in this case the values for each 
day are confused and does not return the real values. When I set dates within 
the same month, there is no problem and real values are shown.

Steps to reproduce issue:
1. Change the start and end dates of the analytics query and set them in 
different months

Expected output:
The real analytics values (eg: visits, pageviews...) for each day I have set.

Actual results:
For some reason when you set different months it shows only the first 31 days 
and shows wrong values (eg visit count, etc)

Notes:
The same problem appears when you set dimensions to "hour" and set start and 
end dates in different days (only first 24 hours are shown and with wrong 
values). I'm programming in PHP and using data_ga->get function ( 
$analytics->data_ga->get(profileId, startDate, endDate, $metrics, $optParams) 
). Values for variables could be $metrics="ga:visits" and 
$optParams=array('dimensions'=>'ga:day'). Maybe there's another function (as 
instead of get()) for this behavior.

Thank you

Original issue reported on code.google.com by juanvi...@gmail.com on 25 Jun 2012 at 4:02

GoogleCodeExporter commented 9 years ago

Original comment by pfrise...@google.com on 16 Apr 2014 at 4:50