<@U0RQY0KK5>: Is there a way to query that somethi...
# prisma-whats-new
g
@nilan: Is there a way to query that something doesn’t exist in the permissions?
n
@gmuresan can you make an example?
g
Copy code
query ($input_modelId: ID!, $user_id: ID!) {
  OR: [{
    NoModelExists(
       filter(
         id: $input_modelId
       )
     )
  }, {
  SomeModelExists(
    filter: {
    
      id:$input_modelId
      clientCompany: {
      	user:{
          id: $user_id 
        } 
      }
    }
  )
}
}
I want to do something like the above
n
This is not possible right now, as no such top-level field exists. But I wonder, doesn't our API return an error when you enter a
modelId
that does not exist?
g
this has to do with the issue we talked about last week. The object is being created with a nested mutation, so I can’t count on the model being created first
n
I see. Didn't you have luck splitting up the mutations?