mirror of
https://github.com/lukevella/rallly.git
synced 2025-07-25 20:27:44 +02:00
🗃️ Remove unused unique indexes from database
This indexes are only slowing things down
This commit is contained in:
parent
293f5c80ef
commit
3f94a0e276
2 changed files with 8 additions and 2 deletions
|
@ -0,0 +1,8 @@
|
||||||
|
-- DropIndex
|
||||||
|
DROP INDEX "Comment_id_pollId_key";
|
||||||
|
|
||||||
|
-- DropIndex
|
||||||
|
DROP INDEX "comments_id_poll_id_key";
|
||||||
|
|
||||||
|
-- DropIndex
|
||||||
|
DROP INDEX "participants_id_poll_id_key";
|
|
@ -71,7 +71,6 @@ model Participant {
|
||||||
updatedAt DateTime? @updatedAt @map("updated_at")
|
updatedAt DateTime? @updatedAt @map("updated_at")
|
||||||
|
|
||||||
@@index([pollId], type: Hash)
|
@@index([pollId], type: Hash)
|
||||||
@@unique([id, pollId])
|
|
||||||
@@map("participants")
|
@@map("participants")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -122,7 +121,6 @@ model Comment {
|
||||||
createdAt DateTime @default(now()) @map("created_at")
|
createdAt DateTime @default(now()) @map("created_at")
|
||||||
updatedAt DateTime? @updatedAt @map("updated_at")
|
updatedAt DateTime? @updatedAt @map("updated_at")
|
||||||
|
|
||||||
@@unique([id, pollId])
|
|
||||||
@@index([userId], type: Hash)
|
@@index([userId], type: Hash)
|
||||||
@@index([pollId], type: Hash)
|
@@index([pollId], type: Hash)
|
||||||
@@map("comments")
|
@@map("comments")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue