DrizzleORM v0.30.5 release
Mar 27, 2024
New Features
$onUpdate
functionality for PostgreSQL, MySQL and SQLite
Adds a dynamic update value to the column.
The function will be called when the row is updated, and the returned value will be used as the column value if none is provided.
If no default
(or $defaultFn
) value is provided, the function will be called when the row is inserted as well, and the returned value will be used as the column value.
Note: This value does not affect the
drizzle-kit
behavior, it is only used at runtime indrizzle-orm
.
Fixes
- Insertions on columns with the smallserial datatype are not optional - #1848