dxkyy
dxkyy
PPrisma
Created by dxkyy on 12/11/2024 in #help-and-questions
Many-to-many relationship not showing in prisma studio?
No description
3 replies
PPrisma
Created by dxkyy on 12/11/2024 in #help-and-questions
Can I access a database, which was created with prisma, with a normal sql driver?
I can connect to my database using sqlx in rust and fetch data, but when I try to insert data I'm getting an error
Created: Err(Database(PgDatabaseError { severity: Error, code: "42601", message: "syntax error at or near \"#\"", detail: None, hint: None, position: Some(Original(55)), where: None, schema: None, table: None, column: None, data_type: None, constraint: None, file: Some("scan.l"), line: Some(1244), routine: Some("scanner_yyerror") }))
Created: Err(Database(PgDatabaseError { severity: Error, code: "42601", message: "syntax error at or near \"#\"", detail: None, hint: None, position: Some(Original(55)), where: None, schema: None, table: None, column: None, data_type: None, constraint: None, file: Some("scan.l"), line: Some(1244), routine: Some("scanner_yyerror") }))
My schema looks like this:
model Artist {
external_urls Json
href String
id String @id
name String
type String
uri String
Track Track? @relation(fields: [trackId], references: [id])
trackId String?
Album Album? @relation(fields: [albumId], references: [id])
albumId String?
}
model Artist {
external_urls Json
href String
id String @id
name String
type String
uri String
Track Track? @relation(fields: [trackId], references: [id])
trackId String?
Album Album? @relation(fields: [albumId], references: [id])
albumId String?
}
9 replies