butlerx / gatsby-source-google-spreadsheets

A source plugin for Gatsby that allows reading data from Google Sheets.
MIT License
39 stars 10 forks source link

Query from multiple sheets #2

Closed newswim closed 4 years ago

newswim commented 4 years ago

First off, this plugin is really cool and worked like a charm right out of the box.

There's one thing that I don't see a way of handling right now. I have a couple google forms populating data into two different google sheets. Can you see a way to support this?

Right now my query looks like:

query MyQuery {
  allGoogleSheet {
    nodes {
      candidates {
          ...

I'd like to add another field at the same level as "candidates" called "jobs" that would reference a different sheet id.

This is for a community project, https://github.com/techmilldenton/denton-works

newswim commented 4 years ago

User error, the additional worksheets are getting picked up, it just didn't have data initially, which may have been why I wasn't seeing them in the schema. Thank you again!!!