Is there a way to filter queries by where nodes do...
# prisma-whats-new
a
Is there a way to filter queries by where nodes don’t have a specific type of related nodes?
n
a
That works in the playground but Apollo complains about
Unexpected Name "null"
.
n
Ah... you need to use a variable instead of inlining
null
with Apollo
it's probably best if you use a variable for the whole filter
for example"
Copy code
query items($filter: ItemFilter!) {
  allItems(filter: $filter) {
    id
  }
}
Copy code
const variables = {filter: {parent: null}}
a
All right, thank you very much 🙂