Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey all,
I am working on web analytics here at QlikTech and am wondering if anyone else has tried to hook Google Analytic's API into QlikView. Google's analytics is certainly a great value but I am really interested to see how much more powerful the data can be when tied with QlikView.
anyway, if you have any thoughts please let me know, send me a PM or add below.
Thanks and look forward to exploring this
Jonathan Moody
Global Online Lead Gen
QlikTech International
Hi All
we we try this application with user name and password,id
it give me error kindly help me urgent basic we are facing same problem last 1 month .
Regards
Ashish
Hi Ashish,
What kind of error do you have? IF you using proxy on your development PC you shoud use proxy parameter with the java code as below:
java -Dhttp.proxyHost=192.168.0.4 -Dhttp.proxyPort=8080 \ -Dhttps.proxyHost=192.168.0.4 -Dhttps.proxyPort=8443 \ -jar GoogleAnalyticsClient-20100115.jar -u foo@bar.com -p mypassword -f 123456 \ -d ga:date,ga:country -m ga:visits,ga:pageviews,ga:newVisits \ -s 2009-01-01 -e 2009-01-07 --filters=ga:country=Turkey.
Best Regards,
Error 1) Security alert unauthorized statment
after execute this another error will come.
error 2) field not found.
And where we use this code i don't know much more about this code.
Kindly help me
Regards
Ashish
hi
i am waiting for your reply.
Regards
Ashish
Hi Ashish,
If you are sure about the password and username ; then the problem can be related with your proxy setttings. Please send your whole statement to me for checking.
Best Regards,
Hi Asim
Thanks for reply my question.
My statement are.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
// Google Analytic settings
SET gUserName='';
SET gPassword='';
SET gProfileId='';
// Date period
SET gDateStart='2010-01-01';
SET gDateEnd='2010-01-07';
// Dimensions & Metrics Reference
// See http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html for details.
SET gDimensions='ga:date,ga:country';
SET gMetrics='ga:visits,ga:pageviews,ga:newVisits';
// Fetch data from Google Analytics into visits.csv
/*
-u Login name for your Google Account (required)
-p Password for your Google Account (required)
-f Your Google Analytics profile ID (the number used in your Google Analytics code snippet) (required)
-o File to write the output CSV (standard output by defaults
-d Dimensions to be displayed in your report (default: ga:date)
-m Metrics to be displayed in your report (default: ga:visits,ga:visitors,ga:pageviews)
-h Print a help screen
-n Do not print the header row
-s Fetch data starting at day (YYYY-MM-DD) (default: a week ago = 2009-09-23)
-e Fetch data up to day (YYYY-MM-DD) (default: today = 2009-09-30)
*/
EXECUTE java -jar GoogleAnalyticsClient-20090930.jar -u $(gUserName) -p $(gPassword) -f $(gProfileId) -d $(gDimensions) -m $(gMetrics) -s $(gDateStart) -e $(gDateEnd) -o visits.csv;
// java -Dhttp.proxyHost=192.168.0.4 -Dhttp.proxyPort=8080 \ -Dhttps.proxyHost=192.168.0.4 -Dhttps.proxyPort=8443 \
//java -Dhttp.proxyHost=192.168.0.4 -Dhttp.proxyPort=8080 \ -Dhttps.proxyHost=192.168.0.4 -Dhttps.proxyPort=8443 \ -jar GoogleAnalyticsClient-20100115.jar -u foo@bar.com -p mypassword -f 123456 \ -d ga:date,ga:country -m ga:visits,ga:pageviews,ga:newVisits \ -s 2009-01-01 -e 2009-01-07 --filters=ga:country=Turkey.
// Load data from visits.csv
Directory;
LOAD ga:date,
ga:country,
ga:visits,
ga:pageviews,
ga:newVisits
FROM
visits.csv
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Kindly check it and helping me.
Regards
Ashish
Your statement looks like ok, but you should raplece the java code with the latest version :
GoogleAnalyticsClient-20100115.jar
http://support.gooddata.com/entries/65253-google-analytics-export-tool
Kind Regards,
Dear Kasim
i have put new code but it give me error
kindly check it my code again.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
// Google Analytic settings
SET gUserName='noel@cleartrip.com';
SET gPassword='advertising';
SET gProfileId='25040351';
// Date period
SET gDateStart='2010-01-01';
SET gDateEnd='2010-01-07';
// Dimensions & Metrics Reference
// See http://code.google.com/apis/analytics/docs/gdata/gdataReferenceDimensionsMetrics.html for details.
SET gDimensions='ga:date,ga:country';
SET gMetrics='ga:visits,ga:pageviews,ga:newVisits';
// Fetch data from Google Analytics into visits.csv
/*
-u Login name for your Google Account (required)
-p Password for your Google Account (required)
-f Your Google Analytics profile ID (the number used in your Google Analytics code snippet) (required)
-o File to write the output CSV (standard output by defaults
-d Dimensions to be displayed in your report (default: ga:date)
-m Metrics to be displayed in your report (default: ga:visits,ga:visitors,ga:pageviews)
-h Print a help screen
-n Do not print the header row
-s Fetch data starting at day (YYYY-MM-DD) (default: a week ago = 2009-09-23)
-e Fetch data up to day (YYYY-MM-DD) (default: today = 2009-09-30)
*/
//EXECUTE java -jar GoogleAnalyticsClient-20090930.jar -u $(gUserName) -p $(gPassword) -f $(gProfileId) -d $(gDimensions) -m $(gMetrics) -s $(gDateStart) -e $(gDateEnd) -o visits.csv;
EXECUTE java -jar GoogleAnalyticsClient-20100127.jar -u noel@cleartrip.com -p advertising -f 25040351\-d ga:date,ga:country -m ga:visits,ga:pageviews,ga:newVisits\ -s 2009-01-01 -e 2009-12-31 --start-index=2001 --max-results=2000;
// java -Dhttp.proxyHost=192.168.0.4 -Dhttp.proxyPort=8080 \ -Dhttps.proxyHost=192.168.0.4 -Dhttps.proxyPort=8443 \
//java -Dhttp.proxyHost=192.168.0.4 -Dhttp.proxyPort=8080 \ -Dhttps.proxyHost=192.168.0.4 -Dhttps.proxyPort=8443 \ -jar GoogleAnalyticsClient-20100115.jar -u foo@bar.com -p mypassword -f 123456 \ -d ga:date,ga:country -m ga:visits,ga:pageviews,ga:newVisits \ -s 2009-01-01 -e 2009-01-07 --filters=ga:country=Turkey.
// Load data from visits.csv
Directory;
LOAD ga:date,
ga:country,
ga:visits,
ga:pageviews,
ga:newVisits
FROM
visits.csv
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Regards
Ashish Kumar
Hi,
I attached a qvw that I modified based on your code. Tested it on my side, and it is working fine. (You need to replace the username, password and ProfileID with your Google Analytic details)
If you are still facing problem with the java program, try running in command prompt and see what error message it is giving.