Sequences created by using the *serial column types in postgres are not tracked by migrations.
I mistakenly created a reference column with type bigserial rather than bigint. After fixing the mistake and generating the migration that changed the column type, the underlying sequence was not deleted and the default on the column was still in place.
Similarly, renaming a column that has an implicit sequence attached will not rename the sequence.
Expected behavior
I would expect the generated migration to also update the underlying sequences.
What version of
drizzle-orm
are you using?0.31.2
What version of
drizzle-kit
are you using?0.22.7
Describe the Bug
Sequences created by using the
*serial
column types in postgres are not tracked by migrations.I mistakenly created a reference column with type
bigserial
rather thanbigint
. After fixing the mistake and generating the migration that changed the column type, the underlying sequence was not deleted and the default on the column was still in place.Similarly, renaming a column that has an implicit sequence attached will not rename the sequence.
Expected behavior
I would expect the generated migration to also update the underlying sequences.
Environment & setup
At least when targeting postgres for migrations.