Industrial
07/02/2022, 11:56 AM'Error: \nInvalid `prisma.todo.create()` invocation:\n\n\n Null constraint violation on the fields: ()\n at RequestHandler.handleRequestError
Richard Ward
07/02/2022, 12:12 PMprisma migrate
or prisma db push
?Industrial
07/02/2022, 12:13 PMIndustrial
07/02/2022, 12:14 PMIndustrial
07/02/2022, 12:15 PMINSERT INTO "public"."Todo" ("id","label","completed","createdAt","updatedAt","listId") VALUES ($1,$2,$3,$4,$5,$6) RETURNING "public"."Todo"."id"
Industrial
07/02/2022, 12:15 PMIndustrial
07/02/2022, 12:16 PMIndustrial
07/02/2022, 12:18 PMList
object works fine:
INSERT INTO "public"."List" ("id","label","createdAt","updatedAt") VALUES ($1,$2,$3,$4) RETURNING "public"."List"."id"
where data is just
{
label: "asdfasdfsadf",
}
Industrial
07/02/2022, 12:19 PM{
label: "asdfasdf",
list: {
connect: {
id: "cl53un75d0060s6lvtxvq1is2",
},
},
project: {
},
}
@Richard Ward sorry if this is a flood of information, just trying to give you as much context as possible 😄Industrial
07/02/2022, 12:27 PMList
, Project
, Tag
but not Todo
. I have one non optional column label
in there and when I fill it in the green Save 1 change
button is greyed out.
Definitely something going on here 😄Industrial
07/02/2022, 12:28 PMIndustrial
07/02/2022, 12:31 PMprojectId
and project
properties were not optional. I was expecting them to be.Richard Ward
07/02/2022, 12:35 PM