drizzle-orm icon indicating copy to clipboard operation
drizzle-orm copied to clipboard

[BUG]: migration to type `serial` for postgres is wrong

Open Perdolique opened this issue 1 year ago • 0 comments

What version of drizzle-orm are you using?

0.33.0

What version of drizzle-kit are you using?

0.24.2

Describe the Bug

I've changed column in schema from text to serial and got incorrect migration:

ALTER TABLE "woof" ALTER COLUMN "id" SET DATA TYPE serial;--> statement-breakpoint

But type serial doesn't exist in postgres.

Expected behavior

Migration was generated correctly, or some kind of notice was added that it's not possible.

Environment & setup

No response

Perdolique avatar Sep 21 '24 21:09 Perdolique