stacker.news/prisma/migrations/20240219144139_add_poll_exp.../migration.sql

7 lines
177 B
SQL

-- AlterTable
ALTER TABLE "Item" ADD COLUMN "pollExpiresAt" TIMESTAMP(3);
UPDATE "Item"
SET "pollExpiresAt" = "created_at" + interval '1 day'
WHERE "pollCost" IS NOT NULL;