Prisma

P

Prisma

The official Discord server of Prisma! Find us online at prisma.io

Join

Recommendations not showing up

Started using Optimize. Clicked in recording, saw the queries coming. Stopped the recording. Clicked in the recommendations: "There are no recommendations just yet, they will appear after you end your recording.". Out of 9 recording, I only got recommendations in 2. Is that a bug in your UI?...

Local development with Prisma Postgres

does anyone know what version of the cli makes this port option available? https://www.prisma.io/docs/postgres/database/local-development#2-applying-migrations-and-seeding-data I'm on 6.8.2 and it doesnt' seem to be available...

Speeding up DB seeding

I'm wondering if there is a quicker way for seeding my database. I'm working on software to manage self storage. I create leases for each storage unit, then I create invoices from the leases then payment records from those invoices. The leases and invoices take 47 seconds and the payment records take 80 mins. I think this is because I have to update each invoice individually to link it to the created payment record.

How to remove `[optimize] HTTP 409 Conflict: There is no active recording to write queries to.`

My current client: ``` const prismaClientSingleton = (): PrismaClient => { return new PrismaClient({...

findMany fetching only 1 entity from "includes"

for this query ```const result = await prisma.member.findMany({ relationLoadStrategy: 'join', where: {...

@prisma/extension-accelerate v2.0.1 breaks types

my selects/includes no longer change the shape of the returned objects additionally, extension-accelerate continues to not have changelog or source code, so it's hard to guess what happened...

changelog for @prisma/extension-accelerate v2.0.0

There are no release notes or changelog to be found anywhere - can you please tell us what neccessitated the major version bump? any breaking changes ?

Server has closed the connection

Thank you for your continued support. I am having trouble with “server has closed the connection.” Prisma does not perform a connection health check after creating a connection, right? If the socket is closed due to TCP Idle Timeout in the network configuration or OS, rather than in the application or Prisma client, Prisma client will continue to hold the connection....

Changing Enum types

Hello I have an Enum that I need to change. The enum was ```ts enum PaymentType { STRIPE CASH CHECK...

Prisma init

npx prisma init Error: Cannot find module '/var/folders/sy/cvxrc_pj4tgdnvnyvrws1n6c0000gn/T/@prisma/cli-init@latest-1747852200000/node_modules/@prisma/cli-init/dist/index.js'...

UserSelect across functions

Does anyone know how I can type this function such that the caller can optionally provide a selection which is then set on thefindUnique and then the return type matches what was selected. If the argument is not set it should return all the fields. ```ts export async function getUser<T extends Omit<UserFindUniqueArgs, "where">>( userId: number,...

In tests, how can I verify a PrismaPromise was actually executed?

I had an application bug just now because I hadn't realized that Prisma's promises don't immediately execute. The database queries only run when the promise is awaited, or when .then() or .catch() is called. This is easy to deal with, and now I know, but I want to cover this in my tests. I'm using Jest, and I'm doing a mockDeep from jest-mock-extended. It's not enough to just test expect(mockDb.myModel.delete).toHaveBeenCalled() because that doesn't assert that it was actually awaited....

Deno guide not working

I'm new with Prisma and i worked a lot with Deno recently so i decided to use it with Prisma. I was following this guide https://www.prisma.io/docs/orm/prisma-client/deployment/edge/deploy-to-deno-deploy from the official documentation but as soon i run the first command to generate the base folder structure, it crashes because deno complains about the missing "npm:" / "node:" prefixes for all the imports in a file inside the dist folder of the @prisma/cli-init package.. I searched online but no one seems to be able to reproduce this. Can someone check it is there is a bug? `deno run --reload -A npm:prisma@latest init --db ...

Cannot see the sql directory in node_modules/@prisma/client

1) I am using --sql flag for generating client 2) version is 6.5 3) no custom output directory, and sql folder is is in correct location But still cannot see the sql directory in node_modules/@prisma/client...

How to handle serialization in Prisma (TypeError: Do not know how to serialize a BigInt)

Hi everyone 👋 I’m encountering an issue when making a query in my app. The request fails with the following error: TypeError: Do not know how to serialize a BigInt...

PrismaClientValidationError: Invalid ` .create()` invocation in

Hi There i'm new in this discord server, I wanna to ask about my project error, here's the details: schema.prisma...

Using Prisma with Both SQLite and PostgreSQL

Hi community ✌️ is there a way to support both SQLite and PostgreSQL with Prisma at the same time? In other words, the user would have the option to use either SQLite or PostgreSQL, with Prisma acting as an abstraction layer. ...

Prisma performance questions

Let's say I have this schema: ```prisma model Tenant { id String @id @default(cuid())...

despite

Error: Could not resolve @prisma/client despite the installation that we just tried.
Please try to install it by hand with pnpm add @prisma/client and rerun pnpm dlx "prisma generate" :pray:.
Error: Could not resolve @prisma/client despite the installation that we just tried.
Please try to install it by hand with pnpm add @prisma/client and rerun pnpm dlx "prisma generate" :pray:.
how to fix this?...

Module '"prisma"' has no exported member 'PrismaConfig'

docs have this import? what am i missing?...
No description