tonid
DTDrizzle Team
•Created by tonid on 9/13/2023 in #help
PostgresError: null value in column "id" of relation "pairs" violates not-null constraint
Hello, I am fairly new to Drizzle and working with databases, so I am running into a problem that I am unsure how to solve and hope that you can help me with it.
I use Directus CMS to create all of my tables. Then, I wrote schema.ts (using introspect and making a couple of manual changes).
So, one of my tables looks like this:
Now whenever i try to insert new pair like this
I get the following error:
PostgresError: null value in column "id" of relation "pairs" violates not-null constraint
What confuses me is that in Directus, I have checked 'ON CREATE: Generate and Save UUID,' which is working just fine.
Please help me understand how I can get around this error.
16 replies