🔮 Sanity Create is here. Writing is reinvented. Try now, no developer setup

Answers from the community about GROQ

Some of the conversations between community members on questions, suggestions and tips for using Sanity. Join our Slack to be a part of it.

TopicCategoriesFeaturedRepliesLast Updated
How to get the number of nested/children components in a GROQ query.4Jan 19, 2024
Issue with fetching data from an array of references and non-references in a groq query.4Dec 14, 2023
Error: unable to resolve image URL from source (undefined)14Sep 11, 2022
Warning: Data for Page Exceeds the Threshold of 128 kB12Aug 17, 2022
GraphQL query resolving references on a _raw field in Gatsby3May 17, 2022
Custom Document Views - Is it Even Possible to Use the Structure Builder?10Apr 21, 2022
Is there a way to write a groq query that checks if a boolean is true, and if so, returns an array of referenced documents?...8Feb 1, 2021
Hey all - what’s the quickest way to batch delete all documents of a certain type? It looks like the `sanity` cli tool allows...5Jan 29, 2021
In the tutorial, there is samples of what the API returns as JSON. Is there a way to view these ?12Jan 11, 2021
hello guys, I noticed that the data I fetch from my sanity studio to my front end are displayed randomly and I don't want...5Dec 20, 2020
Issue with Sanity GROQ fetch returning string data with zero width spaces.3May 16, 2024
Do sub queries inside GROQ count as individual queries towards the plan quota?3Apr 9, 2024
Issue with groq query not returning desired result on front end11Mar 22, 2024
Groq query issue with getting movies and character names for each person in the Sanity movies database.4Mar 18, 2024
Transforming array of objects into named object in GROQ query3Feb 29, 2024
Comparing arrays in GROQ query to find intersections.5Feb 28, 2024
How to get only the published results on GROQ in Sanity.io.4Feb 12, 2024
GROQ queries and security in Sanity.io6Feb 7, 2024