With a datamodel like this: ``` type User { id...
# orm-help
c
With a datamodel like this:
Copy code
type User {
    id: ID! @id
    name: String!
    email: String! @unique
    active: Boolean @default(value: false)
}

type EmailVerification{
    id: ID! @id
    verificationCode: String!
    user: User!
}
Is it possible to query for the email verification where
user.email=test@example.com
I’m trying to query it like this but it’s not working and I’ve tried a bunch of different versions to no avail
Copy code
let emailVerification = await context.prisma.emailVerifications({
        where:{
          user: {connect: {email: args.email}}
        }
      });
I’m wondering if it’s a requirement to have a field on user which links to the EmailVerification Type and I’ll have to do something like.
Copy code
context.prisma.users({
        where: {
          email: args.email
        }
      }).emailVerifications();