Prisma

P

Prisma

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

Join

"Missing required environment variable: DATABASE_URL" after Migrating to prisma.config.ts

I'm trying to migrate to the new prisma.config.ts as outlines here. I'm running into this error.
Failed to load config file "D:\Projects\cafeBot\api" as a TypeScript/JavaScript module. Error: PrismaConfigEnvError: Missing required environment variable: DATABASE_URL
Failed to load config file "D:\Projects\cafeBot\api" as a TypeScript/JavaScript module. Error: PrismaConfigEnvError: Missing required environment variable: DATABASE_URL
...

Prisma query

Hi Guys I am building a full-stack application using turbo-repo. Soo my backend is using serverless AWS and I have a shared database folder which I import from. When using the query system I had to set an env variable: PRISMA_QUERY_ENGINE_LIBRARY to tell pull the generated stuff from the right place. This has caused a lot of issues around the lambda sizes being massive! Soo I found the new way of using the query_compiler_bg.wasm. But I have the same issue where it is not pointing to the right generated folder as it in in a separate folder. soo where it is trying to find it from here: /Users/work/repos/project/services/employer/src/generated/prisma/query_compiler_bg.wasm...

Types for the experimental.extensions option don't work in 6.18.0=

If I set extensions to true in my prisma config, such as ``` export default { experimental: {...

Big data statistics

Hi there, I’m building an app that gonna saves games played by players on a competitive game. I tried to make some statements about how much games should we expect to save each day. ...

code: 'ECONNRESET'

Generating Prisma client... npm warn Unknown user config "scripts-prepend-node-path". This will stop working in the next major version of npm.
Downloading Prisma engines for Node-API for debian-openssl-3.0.x [] 0%node:internal/process/promises:391
triggerUncaughtException(err, true /* fromPromise */); ^...
No description

Rust-less engine is not stable in production

https://github.com/prisma/prisma/issues/27990 https://github.com/prisma/prisma/issues/28152 The rust-less engine is broken, it technically works but errors constantly due to connections being killed making it unusable in production. ...

Incorrect type inferred

Hello, I’m running into an issue with Prisma and would appreciate some help I’m trying to create a generic function for paginating my models with a fully generic type. Here’s the function:...

Do we also install a non open source sofware when we install prisma?

I know that prisma studio isn't open source. Does that mean when we npm install prisma -D are we also installing a non open source software?

P5010 - Can't figure it out

Hello - I'm trying to implement Accelerate but I'm getting a P5010 and cannot figure out what it is. I enlisted chatGPT's help before coming here and still no luck 😂 I've checked the DATABASE_URL 8000 times, including generating like 4 URLs just to see (didn't know with the AWS outage yesterday). I am using a Heroku postgres DB but I don't think that matters yet because I think the issue lies in the connection between the interface and Prisma because Prisma isn't logging anything. If you're able to pull requests, I have a request ID (992162f33b9f05a1) - I can generate more if need be....

[6.17.x] Extremely slow formatting and lint on save in vscode

Hello! Just posting to see if anyone has a fix for prisma taking a long time to format and to save in vscode? We switch from using the wasm and it has become really slow on formatting and saving. prisma.config.ts ```ts import "dotenv/config";...

Many-to-many relation started silently failing to perform joins

Hi Prisma team! My jaw has dropped to the floor. I've a critical problem with the ORM. Many-to-many relations are not joining. As you can see in the code snippet below the query fetches a row and joins the "rawRequirements". There are 311 relations. The count is correct. The join is not working....
No description

Can I customize `reset` behaviour to allow Migrate to with with Aurora DSQL?

Hey folks; I'm using Prisma ORM with an instance of AWS Aurora DSQL. I started from scratch, creating an empty instance of my Dev DB and a corresponding Shadow DB, with a simple schema: ``` datasource db { provider = "postgresql"...

Update Parent Model's updateAt

Whats the best way to handle updating the Parent Models (one) updateAt field when the Child Model (many) has a CRUD operation performed on it. Is there any way to handle this without manually running another mutation?...

Failed to convert rust `String` into napi `string` when selecting columns of leftJoined table

Hello Guys, i am working with a lot of data in my app. Currently i am selecting a date range which includes 1.2 Million entries. Everything worked fine till i reached this amount of data. Now if i try to select 4 columns of a left joined table i am greeted with the following error:...

Prisma + NestJS import issue when using custom client output

When using a custom Prisma Client output directory inside a NestJS project, the generated client cannot be imported correctly — even though the files exist and Prisma successfully generates them. Error: Cannot find module '../../../prisma/generated/prisma' Require stack: - dist/src/libs/prisma/prisma.service.js...
No description

Can't reach database server at `db.prisma.io:5432`

Error [PrismaClientInitializationError]: Invalid prisma.****.findMany() invocation: Can't reach database server at db.prisma.io:5432...

Understand prisma postgres DB restore process, documentation is poor

We have a production outage, we have experienced some production DB data loss. We have backups enabled. We'd like to understand how to do the following: 1. To inspect backups: Is there a way to restore the backup to another database?...

queryRaw returns empty array

I am currently trying to implement vector search with Prisma and MariaDB. The problem I am facing is, that I have to use rawQuery since vectors are not supported by prisma and when I execute my raw Query through prisma.$queyRaw, I get an empty array back.. The exact same query run on DBeaver returns a result though. I am really confused here. What is going on?? My code:...

Postgres Adapter seems to not work with Planetscale Postgres Database.

It seems like the @prisma/adapter-pg does not work with planetscale postgres, every time I've tried i run into the "User denied access on db" error..