louneskmt
DTDrizzle Team
•Created by louneskmt on 9/15/2023 in #help
Any way to replace null by undefined?
Before using Drizzle, I was using the type mapper and the
transform
option of postgres.js
in order to transform undefined
to null
. That way, any inserted undefined
would be inserted as null
in the database, and any null
value in the database would be an undefined
in JS.
I'm looking for a way to do this with Drizzle. AFAIU as I'm still using the postgres.js
connector, I can continue with these options, so the issue is to use undefined
instead of null
in the types. Similarly to changing a column type with .$type<T>()
.
Thanks!49 replies