Google Analytics ODBC Driver Getting Started Guide
- Installing the Google Analytics ODBC Driver
- Creating a Google Service Account
- Configuring an ODBC Data Source
- Connecting Your Application to Google Analytics
You need to create a Google Service Account in the Google console to use the Google Analytics ODBC driver.
- In the Google Developers Console, create a new project.
- Choose the menu button in the top-left corner of the Google Developers Console, expand APIs & Services and choose Library.
- Choose the Google Analytics API tile.
- Choose Enable to enable the Google Analytics API.
- In the Google Developers Console, create a Service Account.
- Copy the Service Account email address as you will need to add this user in your Google Analytics account.
- Add a new key for the service account. Choose a JSON key type.
- Download the certificate to the machine where you will install the Google Analytics ODBC driver.
- Sign into your Google Analytics account.
- Grant the Read & Analyze permission to a new user whose email address is the one you created in the Google Developers Console.
- Download the Google Analytics ODBC driver for your Windows platform. (Registration required.)
Install and license the Google Analytics ODBC driver on the machine where your client application is installed.
For example, if you want to analyse Google Analytics data in Excel, install the Google Analytics ODBC driver on the machine where Excel is installed.
To do this, execute the file distribution that you downloaded in the previous step, and follow the on screen instructions.
The install program starts the Easysoft License Manager, because you cannot use the Google Analytics ODBC Driver until a license is obtained.
The following types of license are available:
- Free time-limited trial license which gives you free and unrestricted use of the product for a limited period (usually 14 days).
- Full license if you have purchased the product. On purchasing the product you are given an authorization code, which you use to obtain a license
In Easysoft License Manager, enter your details.
You MUST enter the Name, E-Mail Address and Company fields.
The E-Mail Address MUST be the same as the address used to register and download from the Easysoft web site or you will be unable to obtain trial licenses.
Choose Request License.
You are asked for a license type.
Do one of the following:
For a trial license click Time Limited Trial and then click Next.
The License Manager asks what software you are licensing. Select Easysoft ODBC-Google Analytics Driver from the drop-down list and then click Next.
If you have obtained an authorization code for a purchased license, select Non-expiring License and then click Next.
The License Manager requests your authorization code.
Enter the authorization code and then click Next.
- For a trial license click Time Limited Trial and then click Next.
- The License Manager displays a summary of the information you entered and allows you to choose the method of applying for your license.
Do one of the following:
Choose On-line Request if your machine is connected to the internet and can make outgoing connections to port 8884.
The License Manager then sends a request to the Easysoft license server to activate your license key automatically. This is the quickest method and results in your details being entered immediately into our support database.
The remaining three options (Email Request, Print Request and View Request) are all ways to obtain a license if your machine is off-line (i.e. does not have a connection to the internet).
Each of these methods involves providing Easysoft with information including your machine number (a number unique to your machine) and then waiting to receive your license key.
Instead of emailing your details to Easysoft, you can enter them directly at the Easysoft web site and your license key will be emailed to you automatically.
To use this method, click View Request, and then visit:
In the Licensing page, enter your machine number (and authorization code for purchased license), click Submit and your license key will be emailed to you.
When you receive the license key, you can activate it either by double-clicking the email attachment or by clicking Enter License on the License Manager main screen and pasting the license key into the dialog box.
Choose Finish to exit the License Manager.
The installation is complete.
- Choose On-line Request if your machine is connected to the internet and can make outgoing connections to port 8884.
Before you can use the Google Analytics ODBC Driver to connect your application to Google Analytics, you need to configure an ODBC data source. An ODBC data source stores the connection details for the target database (e.g. Google Analytics) and the ODBC driver that is required to connect to it (e.g. the Google Analytics ODBC driver).
You configure ODBC data sources in ODBC Administrator, which is included with Windows. How you run ODBC Administrator depends on whether your version of Windows is 32-bit or 64-bit:
I have 32-bit Windows
To run ODBC Administrator on 32-bit Windows, open Administrative Tools in Control Panel, and then open Data Sources (ODBC). (On older versions of Windows, the Control Panel applet that launches ODBC Administrator is labelled Data Sources.)
I have 64-bit Windows
There are two versions of ODBC Administrator on this platform. The version of ODBC Administrator that you need to run depends on whether the application you want to connect to Google Analytics is 32-bit or 64-bit. For the applications covered in this article, refer to the following table to find out the application's architecture.
Application Notes Excel There is both a 32-bit and a 64-bit version of Excel. To find out which version of Excel you have, start Excel, and then start Windows Task Manager. In Task Manager, choose the Processes tab. Look for
Excel.exein the list. If this process name is followed by
*32, your version of Excel is 32-bit. Otherwise, your version of Excel is 64-bit.
If you have a 64-bit application, you need to run 64-bit version of ODBC Administrator. To do this, open Administrative Tools in Control Panel, and then open Data Sources (ODBC). (On Windows Server 2003 and earlier, the Control Panel applet that launches ODBC Administrator is labelled Data Sources. On Windows 8 and later, the Control Panel applet is labelled ODBC Data Sources (64-bit).)
If you have a 32-bit application, you need to run 32-bit version of ODBC Administrator. To do this, in the Windows Run dialog box, type:
I'm not sure whether I have 32-bit or 64-bit Windows
If you are not sure whether your version of Windows is 32-bit or 64-bit, follow the instructions in this Microsoft Knowledge Base article to find out.
Use ODBC Administrator to create a Google Analytics ODBC Driver data source:
- Choose the System DSN tab, and then choose Add.
- In the Create New Data Source dialog box, choose Easysoft ODBC-Google Analytics Driver, and then choose Finish.
Complete these fields in Easysoft ODBC-Google Analytics Driver DSN Setup dialog box:
Setting Value DSN Analytics Description Easysoft Google Analytics Driver
- Enter the full path to the Service Account certificate (JSON format) you created earlier, in the Service Acct File.
- Use the Test button to verify that you can successfully connect to Google Analytics.
Follow these steps to return data from Google Analytics to Microsoft Excel by using the Data Connection Wizard:
Do one of the following:
- For Excel 2007 and later, on the Data tab, in the From Other Sources group, choose Data Connection Wizard.
- For Excel 2003 and earlier, on the Data menu, choose Import External Data, and then choose Import Data.
- For Excel 2003 and earlier, in the Select Data Source dialog box, choose New Source. For Excel 2007 and later, skip this step.
- In the Data Connection Wizard, choose ODBC DSN from the list, and then choose Next.
- Choose your Google Analytics ODBC driver data source from the list, and then choose Next.
- Choose the table that contains the data you want to retrieve, and then choose Next.
- Name and describe your new Data Connection File, and then choose Finish.
- In the Select Data Source dialog box, open your new Data Connection File.
- In the Import Data Dialog box choose the destination cell and worksheet for the data, and then choose OK to return your data to Excel.
Follow these steps to return data from Google Analytics to Microsoft Excel by using Microsoft Query:
Do one of the following:
- For Excel 2007 and later, on the Data tab, in the From Other Sources group, choose From Microsoft Query.
- For Excel 2003 and earlier, on the Data menu, choose Import External Data, and then choose New Database Query.
The New Database Query command uses Microsoft Query to import data. Microsoft Query is an optional feature, which by default is not installed. If you do not have Microsoft Query installed, choosing New Database Query will prompt you to install it. To do this, in Control Panel, choose Programs and Features (or Add or Remove Programs). Choose Microsoft Office (if you installed Excel as part of Office) or Microsoft Excel, and then choose Change. Follow the instructions on screen. Select Choose advanced customization of applications during the Setup wizard if this option is present for your version of Office / Excel. Microsoft Query is located under Office Tools.
When you have installed Microsoft Query, repeat step 1.
- In the Choose Data Source dialog box, choose your Google Analytics ODBC driver data source from the list, and then choose OK.
- In the Query Wizard, choose the columns that contain the data you want to retrieve, and then click Next.
- If you want to return a subset of the data, use the Filter Data screen to filter the results of your query (this is the equivalent of a SQL
WHEREclause), and then click Next.
- If you want to change the sort order of your data, use the Sort Order screen to sort the results of your query (this is the equivalent of a SQL
ORDER BYclause), and then click Next.
- Click Finish to return your Google Analytics data to Excel.