Skip to content

Latest commit

 

History

History
60 lines (38 loc) · 1.76 KB

README.md

File metadata and controls

60 lines (38 loc) · 1.76 KB

Google Sheets DuckDB Engine

This little hack loads DuckDB WASM as a Google Sheets Library to execute, parse and return data.

No query data is sent to the extension, google or anywhere. Everything remains local.

Setup

Install Extension

  • Open a Google Sheets document
  • Browse to Extensions > Apps Script
  • At the left of the Apps Script editor, next to Libraries click ➕
  • In the Script ID field, paste 1BacEJir06S0Kojb53TqhX6ECUO1tNZX6SbQoKAPueC_qdZzij3KkBc1M
  • Click Look up and choose the latest version
  • Click Add and Authorize the Library

image

Extension Usage

Type a query in a cell and execute it with DuckDB. Example:

SELECT * FROM 'https://duckdb.org/data/schedule.csv'

Todo

  • Add Query Form in the sidebar
  • Read Table into DuckDB memory
  • Add dropdown with quick examples


DIY Setup

Follow these steps if you'd like to fork and create your own library based on this code. Not needed for testing.

Manual

Browse to Extensions > Apps Script

image

Copy the .gs + .html and Deploy as Library

image

That's it! You can start using your own custom script in Google Sheets