Blog Banner

The North Data Blog

Company data on your Google Sheets spreadsheet

Google Docs offers API integration, allowing companies like North Data to display their data straight onto a Google Sheets spreadsheet. This feature can be extremely useful in many ways, especially if you would like to enrich your database with the data provided by us. In this article, we will walk you through a step-by-step tutorial on how to enable this feature.

North Data Connections

 

We understand that our customers consume our data in different ways. That’s why we would like to show you an alternative way to make the most of the data we provide. Google allows scripting within the Google Docs applications, making it possible for companies to link their database to Google via API. For instance, this will enable data to be transferred straight from its source into a Google spreadsheet.

For our customers, this means jumping into the driver's seat and steering our data as they wish. For example, you have a Google spreadsheet with a list of companies. You would like to know the number of employees and revenue of each company. With just a few clicks, your spreadsheet will be updated with fresh company data straight from North Data's database.

We have prepared an easy-to-understand tutorial describing every step you need to take to display our data on your Google Sheets spreadsheet. Here is what you need to do to make the most of this feature:

  1. Create a new spreadsheet in Google Sheets

  2. In the top menu, click on “Tools” and then select “Script Editor.”

  3. You are now in Google's Apps Script, where you will enter the North Data script so that Google can connect to our API. Our script is here. Copy our entire script.

     

    Copying the script1 Google Sheets - Copy script v2-1

  4. Paste the North Data script into the scripting area, replacing the entire default text with our script. You need to replace the entire scripting area with our script for it to work.

    Pasting the script2 Google Sheets - Paste Script v2

  5. Paste the API key into the script - the API key will be sent to you upon purchasing our Data Services API. – Activate the API by replacing the placeholder key “XXXX-XXXX” with the API Key. It should look like this.

     

    Adding the API Key2 Google Sheets - API key update v2

  6. Save and run the script by clicking on Save button  and Run button-1.
  7. Google will ask you to review your permission and will prompt you to log into your Google account.
  8. Log into your Google account. Click “Allow” to activate the changes. You're in! The connection has been made, and you can now start using the feature.
  9. Go back to your spreadsheet. You will find a new tab on the menu named “North Data.”

    Activating the script4 Google Sheets - Run, Save, accept permission and show North Data tab

You now have two ways to access our data in your spreadsheet:

Option 1: With your own template

The first column (A) must contain the name of the to be searched company. The second column (B) must have the corresponding city of that company. These two columns are paramount for our database to understand your inquiry, as the company's name and the city are the keys to the information you need. Here is how it should look:

Example 1

Now that you already have the keys to finding the data, you can specify the KPIs you would like to visualize. Ensure you use the exact spelling from the table below, or the script will not work correctly. The available KPIs are the following:

 

Fields in English

Fields in German

Status

Status

Register

Register

Address

Adresse

Lei

Lei

Phone

Telefon

Fax

Fax

Email

E-Mail

Website

Website

VAT Id

USt.-Id.

Industry Code

Wirtschaftszweig

Total assets

Bilanzsumme

Earnings

Gewinn

Revenue

Umsatz

Return on sales

Umsatzrendite

Equity

Eigenkapital

Equity ratio

EK-Quote

Return on equity

EK-Rendite

Employee number

Mitarbeiterzahl

Revenue per employee

Umsatz pro Mitarbeiter

Taxes

Steuern

Tax ratio

Steuerquote

Receivables

Forderungen

Liabilities

Verbindlichkeiten

Pension provisions

Pensionsrückstellung

CEO

Vorstandsvorsitzender

Managing Director

Geschäftsführer

 

For instance, if you would like to have North Data's address and status in your spreadsheet, here is what it should look like:

Example 2

After the columns with the desired KPIs have been added to your document, retrieve the data by selecting one of the “update” options on the “North Data” tab in the menu:

  • Update all: Updates the whole spreadsheet with new information.
  • Update New Entry: Only updates the latest entries added to the document.

After selecting one of the “update” options, a message “Running Script” will appear. Once the action is completed, your spreadsheet will be updated with fresh company data straight from our database.

Updating your spreadsheet6 Google Sheets - Update All

Option 2: Premade Template

On the North Data tab in the top menu, select “Premade Template’. The script will run and load our template onto your spreadsheet. The first two columns will automatically populate with example companies (column A) and cities (column B). Replace these with the companies and cities you want to search. On the North Data tab, select “update all.” Our script will again run and update your spreadsheet with the KPIs you need.


Loading our premade template5 Google Sheets - Premade Template

If something is wrong with the script (e.g., API key input incorrectly, script not pasted entirely, etc.), the following error message will appear:

Error Message

In this case, go back to step 2 and check if you have replaced Google`s placeholder script with the North Data script completely. Then go to step 5 and check that you entered the API Key correctly.

Don’t forget to follow these basic rules when creating or editing your spreadsheet so that the data can be retrieved from our database successfully:

  • Column A: Must contain the name of the company
  • Column B: Must contain the city of the company
  • Desired KPI: Write down the desired KPIs from column C onwards. Write each column title with the exact spelling as in the available KPIs list above. The KPI name is also the key for the script to find the correct information in our database.

If you would like to know more about our Data Services, just send us an email at info@northdata.com or reach out to us by clicking on the button below.

Contact us

Written 30-Jul-2021 15:03:36

Our Posts

Lists by Topic

Subscribe to our blog

Follow us