Prisma

P

Prisma

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

Join

Prisma config parser?

Does the Prisma library come with some kind of parser I can use? I am in need of being able to automatically discover the generated Prisma client, and need a way of parsing and reading the config file.

Prisma v6.9.0

I updated my prisma to v6.9.0 and all typesafe becomes any, which was not happening in 6.8.2

When using the @prisma/adapter-pg I get a module build fail trying to use the prisma client.

I have a turborepo next 14 monorepo that exports the prisma client into my front and back end apps from the database package. I have all my prisma dependencies installed there. I am getting:
Module build failed: UnhandledSchemeError: Reading from "cloudflare:sockets" is not handled by plugins (Unhandled scheme).
Module build failed: UnhandledSchemeError: Reading from "cloudflare:sockets" is not handled by plugins (Unhandled scheme).
Could this have to do with monorepo set up? and not having the postgres installed ...

Getting foreign key error even though foreign row exists

I have two tables connected by a foreign key constraint. My foo table has a foo_uuid column, and my bar table references it via a foo_uuid column. I am trying to call this method: ``` prismaClient.bar.create({ data: { foo_uuid: 123,...

Cannot read undefined of Enum

I am using Next.js with turbopack and I keep getting Error: Cannot read properties of undefined (reading 'BAR') when trying to access an enum as follows: ```ts import { Foo } from '@/generated/prisma/default'; ...

Postgres full text search

Hello, everyone, I have followed this tutorial to learn full-text search, but I want to know if it's possible to apply it on different Language 'Arabic', is it possible and how?

Using queryCompiler, PrismaClient doesn't honor Postgres schema from config

I'm attempting to upgrade to the queryCompiler preview feature and the Postgres adapter. My connectionUrl specifies a Postgres schema (?schema=core), but the PrismaClient throws errors because it "cannot find table public.XXX", implying it does not honor the intended schema value. I have also attempted to provide the schema via the adapter options object, but to no avail. Has anyone else encountered this issue? Any fixes or workarounds?...

Prisma now wants me to have an `app` folder?

Hey guys, I have been using Prisma for a little while, but have taken a break and have just got back into my side project, and noticed that now Prisma is asking me to have a separate app folder? I am not sure I understand, I thought it would generate normally and then you import from @prisma/client? Why do we need to use a separate app folder now? thanks in advance.

Cloudflare Workers

Hi! I’m having trouble using Prisma with Cloudflare D1 on Cloudflare Workers. I created two minimal examples: • ✅ This one works: https://github.com/catpddo/test-d1-hono • ❌ This one fails to run on Workers: https://github.com/catpddo/test-d1...

How to Handle Partial Unique Indexes with Prisma Migrations?

Hey Community, I'm working on a use case where I need to manually modify a Prisma migration file to add a WHERE clause to a unique index. For example: ```sql...

Provider `prisma-client` vs `prisma-client` js with preview features

I have a few questions about the client provider changes v6 -> v7 ```prisma generator client { provider = "prisma-client-js" output = "../app/generated/prisma"...

Health Check of Query Engine timed out

So Im using MySQL and getting this error. how can I solve this?

Multifile schema example not working https://github.com/prisma/dub

I cloned the example https://github.com/prisma/dub and tried running npx prisma generate and get the following error: You can either provide it with --schema argument, set it in your prisma.config.ts, set it as prisma.schema in your package.json,...

Upgraded to pro, queries all failing "Accelerate was not able to connect to your database"

I just upgraded to Pro because Petra emailed me recommending it, but now all queries failling - nothing changed in my code side and database url is CORRECT `` This request could not be understood by the server: {"type":"UnknownJsonError","body":{"code":"P6008","message":"Accelerate was not able to connect to your database. The underlying error is: Can't reach database server at database-ommitted.ewr0.db.prisma-data.net:5432\n\nPlease make sure your database server is running at database-01jvakzxrv8p865yd2...
No description

data types on query

Ciao, i'm using prisma 6.8.2 and @prisma/extension-accelerate 2.0.1 on prisma.io postgres db. When i write a query, i'm forced to type manually output otherwise it doesn't build. Example const res = (await dbClient.assignment.findUnique({...

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.