Next auth with extended columns not able to create a user
I'm trying to create an app that relies on role based authentication with next auth and drizzle, the problem is when I try to create a user by signing in I get the following error, even tough there's a default applied in the schema:
This is my table:
Shouldn't those columns not be null and instead have the default value instead of null?
1 Reply
When i create them manually through drizzle studio it works fine
I put in the not null constraint because if it doesn't have it there for some reason it overides the default and inserts as null
I've tried like this as well but no success
It seems to be a next-auth issue, when i create the user via credentials it works fine, even when not specified it uses the default and create the user with the values expected, but when the user is created via their sso providers it breaks trying to insert null