Common query code

Following on from Query from GAS,  and Query scriptDB from GAS here's the common code they each need to construct and compile the queries and results.

common query code

It needs a few basic utility functions as used all over on this site from the mcpher shared library.

The results

The scriptDB version is a lot cleaner and straightforward than the parse version. It takes a lot longer to populate the table in the first place though, with lots of execution time exceeded woes.

For more about, see
For help and more information join our forumfollow the blogfollow me on twitter

You want to learn Google Apps Script?

Learning Apps Script, (and transitioning from VBA) are covered comprehensively in my my book, Going Gas - from VBA to Apps script, All formats are available from O'ReillyAmazon and all good bookshops. You can also read a preview on O'Reilly

If you prefer Video style learning I also have two courses available. also published by O'Reilly.
Google Apps Script for Developers and Google Apps Script for Beginners.