Files
learn-languages/prisma/migrations/20260106112014_relax_unique_constraint_on_pairs/migration.sql
goddonebianu 9715844eae
All checks were successful
continuous-integration/drone/push Build is passing
宽松化pairs表约束
2026-01-06 19:23:35 +08:00

12 lines
435 B
SQL

/*
Warnings:
- A unique constraint covering the columns `[folder_id,language1,language2,text1,text2]` on the table `pairs` will be added. If there are existing duplicate values, this will fail.
*/
-- DropIndex
DROP INDEX "pairs_folder_id_language1_language2_text1_key";
-- CreateIndex
CREATE UNIQUE INDEX "pairs_folder_id_language1_language2_text1_text2_key" ON "pairs"("folder_id", "language1", "language2", "text1", "text2");