python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
Accessing models by using a variable
How can I dynamically access a model in prisma?
return await prisma[modelName].create({ data })
... seems not to work.
I am looking for a way to access my models by using a variable. How can this be ...
Timo Müller
Votes: 0
Answers: 1
Generated types in Prisma do not have optional fields as defined in the schema
Using Prisma v 3.8.1
My User Model is
model User {
id Int @id @default(autoincrement())
createdAt DateTime? @default(now())
email String ...

Subhendu Pratap Singh
Votes: 0
Answers: 1
is it possible to user `where` and `count` to return the count for a specified field?
I am trying to use Prisma to return a count for a boolean field where it equals 'true'.
To give some context, on the frontend I am trying to calculate the workouts that have been completed by a user a...
adherb
Votes: 0
Answers: 1
How to run Prisma schema update without erasing the PostgreSQL data?
I have a PostgreSQL db that is used by a Nest.Js / Prisma app.
We changed the name of a field in the Prisma schema and added a new field.
Now, when we want to update the PostreSQL structure, I'm runni...

Aerodynamika
Votes: 0
Answers: 2