Leo Li
08/12/2021, 12:53 AMA
and B
. Is there a way to name it meaningful? Or I have to construct it explicitly?Melvin Gaye
08/12/2021, 2:20 AMLeo Li
08/12/2021, 3:40 AMmodel PostToComment {
post Post @relation(fields: [postId], references: [id])
postId Int @map("post_id")
comment Comment @relation(fields: [commentId], references: [id])
commentId Int @map("comment_id")
@@unique([postId, commentId])
@@index([commentId])
@@map("_PostToComment")
}
Ryan
08/12/2021, 6:16 AMA
and B
as the table names.Leo Li
08/12/2021, 1:14 PMRyan
08/12/2021, 1:17 PMLeo Li
08/12/2021, 2:30 PM