All Collections
Versions 3.0 and 2.0
Can I fetch relational data from a sheet in my Workspace?
Can I fetch relational data from a sheet in my Workspace?
Elisa Dinsmore avatar
Written by Elisa Dinsmore
Updated over a week ago

This article is for Flatfile's Workspaces. If you'd like to check out the latest version of the Flatfile Data Exchange Platform, click here!

Yes! You can use Flatfile’s GraphQL API to pull relational data from sheets in your Workspace. Using GraphQL to pull relational data is an advanced use case, but it will allow you to pull both datasets in a single GraphQL query.

In order to do this, we suggest a GraphQL query like the following:

query getSheetRecords($sheetId: UUID!, $limit: Int, $skip: Int, $filter: String,  $status: String, $errorFilter: String, $resolveNested: Boolean){
getSheetRecords(sheetId: $sheetId, limit: $limit, skip: $skip, filter: $filter, status: $status, errorFilter: $errorFilter, resolveNested: $resolveNested) {
rows {

This will fetch related (also called “nested”) data from your Workspace sheet.

In addition to GraphQL, you can also pull related datasets from the Workspace API. Simply set the “nested” query parameter to “true” in order to return both the parent and child dataset.

Did this answer your question?