Google Sheets is great for quickly spinning up dashboards and analysis, but getting raw data into Sheets can be tedious. In this post we cover a few ways to get data from your MySQL database into Google Sheets.
4) You might also want to change the , but you don't go too crazy, Sheets has a hard limit of 5 million cells and the query will take longer to run with more rows.
5) Save the file and refresh / refresh the Sheet. You'll see a new menu option of "SeekWell Lite" show up.
6) The script is set up to read the query from and write the results your active cell, so you'll need to add a sheet called "query" and add the query below in cell (skip if you copied the Sheet above).
7) Go back to , click in cell (or any other cell) and click "SeekWell Lite" → "Run SQL". In a few moments you'll see the data show up!
A few problems with this approach
Sharing the script with your team and adding the script to different Sheets is a bit of a pain. You can publish an addon, but that comes with some overhead.
Scheduling / automating refreshes can be cumbersome when you need many different queries going to many different Sheets
Google's JDBC service doesn't work for Postgres or Snowflake, RedShift and requires a long list of whitelisted IP's. It also doesn't support SSH.
A lot of people hate paying for things they can do for free, but if you should always do some "napkin math" when making the "build vs. buy" decision. In the case of automating reports, the ROI can be pretty high, especially if you have several daily, hourly, or near real time dashboards you need to keep updated. I'm clearly biased towards SeekWell since we made it, so here's our pitch:
Takes < 90 seconds to get your first schedule set up
A shared code repository with every query anyone else on your team has ever written
You can query other Sheets, CSVs
Support for MySQL, Postgres, Snowflake, Redshift, and SQL Server