Fetch Google Trend information automatically in Google Sheets

3.9k Views Asked by At

To keep analyse and track of the demand within the tourism industry I am using Google Trends very often. The problem is it is a lot of work that we have to do manually. The current process is:

  • Go to Google Trends
  • Fill in search query, change filter
  • Download .csv
  • Upload to a Google sheet
  • Change data to columns
  • Add a formula
  • Create a graph

It would be wonderful if it was / is possible to preform a part of this process automatically on a weekly basis for one or multiple search terms. In another post I've found this script but I constantly get a error.

TypeError: Cannot read property 'getValue' of nullDetails

or

TypeError: Cannot read property 'getValue' of null (line 45, file "Code")

How can I implement this script in my google sheet (I've already added it in Google scrips and the menu button is there) and what kind of data do I have to add in the sheet itself?

UPDATE: Link to spreadsheet https://docs.google.com/spreadsheets/d/1ElTr2UsBaZdZse6-LcD3inST-Sp5vOHOZQSKESpmDcM/edit#gid=0

Hope that some can help me :) Thanks!

Kind regards, Sami

0

There are 0 best solutions below