Insert/update statements not executed during migrations

Hi.

Does Drizzle support DML statements when running migrations? My use case is to add a new column, populate it and then make it not null.

ALTER TABLE "conversations" ADD COLUMN "channel_id" text;
--> statement-breakpoint
UPDATE "conversations" SET channel_id = 'some value';
--> statement-breakpoint
ALTER TABLE "conversations" ALTER COLUMN "channel_id" SET NOT NULL;


PostgresError: column "channel_id" of relation "conversations" contains null values
Was this page helpful?