Hey. I'm using Python Prisma client and I'm gettin...
# orm-help
l
Hey. I'm using Python Prisma client and I'm getting some data which is not being inserted into my column. For some reason or another my
panelChannelId
is
null
, when console logging the value which I am trying to insert, it returns a string. So I'm unsure why it is not putting the data into my db.. I also tried hard coding a value for the
panelChannelId
key, and it still appears as null.
Copy code
await self.client.prisma.serververification.create(data={
            "guildId": str(interaction.guild.id),
            "enabled": True,
            "logChannelId": None,
            "panelMessageId": str(panel_message.id),
            "panelChannelId": str(verification_channel.id),
            "verifiedRoleId": str(verification_role.id),
        })
Copy code
model serververification {
  id             Int     @id @default(autoincrement())
  guildId        String  @db.VarChar(20)
  enabled        Boolean @db.Bit(1)
  logChannelId   String? @db.VarChar(20)
  panelMessageId String? @db.VarChar(20)
  panelChannelId String? @db.VarChar(20)
  verifiedRoleId String? @db.VarChar(20)

  @@index([guildId], map: "guildId_fkey")
}
1
n
Hi Logan 👋 GitHub Discussions in
prisma-client-py
repository would be an ideal place to ask questions related to the Prisma Python Client. @Robert Craigie might be able to help you out here.
l
Brilliant, thanks I'll head on over there 🙂
r
If anyone else comes across this, the issue was that the generated client was out of date, regenerating the client fixed the issue!
🙌 1