Database Reference
In-Depth Information
sheet already
* existed, it will be cleared and rewritten (so don't
put stuff you
* want to keep in the results sheet). Note that
Google Spreadsheets
* has a limit of about 400,000 cells, so if you have
large query
* results, you might find yourself hitting this limit
pretty quickly.
*/
// Name of the sheet that will contain the query
results. This page
// will be cleared every time the query is run.
var QUERY_RESULTS_SHEET = 'Query Results'
// Name of the user property where we save the project
ID.
var PROJECT_ID_PROPERTY = 'PROJECT_ID'
// Number of results to return from BigQuery per page.
var MAX_RESULTS_PER_PAGE = 1000
/** Installs a BigQuery menu to allow you to run
queries. */
function onOpen() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var menuEntries = [];
// Create a menu link to the 'runQuery' function. To
run a query,
// select the cells that contain your query and then
select 'Run
// a query from the BigQuery menu.
menuEntries.push({name: "Run a query", functionName:
"runQuery"});
// Before you can run a query, you need to set a
project ID to use
// with the query. You can do this by selecting a
Search WWH ::




Custom Search