Ibad Shaikh
02/03/2022, 2:22 PMprisma.special_password.findFirst()
invocation:\n\n\n Failed to validate the query: Field does not exist on enclosing type.
at `Query.findFirstspecial_password`"`
• Even the prisma studio is showing the record of this table.
I have also updated prisma from "3.2.1" to "3.9.1" but it still fails. I also cleaned my npm cache but still the same error.
Also used prisma db push and prisma db pull commands but its says The database is already synced.
Prisma Query:
await prisma.special_password.findFirst({
where: {
password: req.body.password,
},
})
• And If I try to call .delete( ) method it throws:
`nUnknown arg password
in where.password for type special_passwordWhereUniqueInput. Available args:\n\ntype special_passwordWhereUniqueInput {\n id?: Int\n}\n\n\n at Object.validate`
It means the query is not considering password as the field of this model. But inside vscode, the password field is provided as a hint which means that this field is supported but when the query is ran, it throws error.Ibad Shaikh
02/03/2022, 3:35 PM