prisma-upgrade-v7

Migrate Prisma ORM projects from v6 to v7 across all breaking changes.

Updated Aug 9, 2026
One-click install
npx skills add https://github.com/mousetailor/doker_and_cd_pipeline --skill prisma-upgrade-v7-mousetailor
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-upgrade-v7
Source: https://github.com/mousetailor/doker_and_cd_pipeline/tree/main/packages/db/.agents/skills/prisma-upgrade-v7
Command: npx skills add https://github.com/mousetailor/doker_and_cd_pipeline --skill prisma-upgrade-v7-mousetailor

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Upgrading from Prisma ORM v6 to v7 introduces breaking changes around the new prisma-client generator, mandatory driver adapters, prisma.config.ts, explicit environment loading, and new generated client entrypoints, and this Skill guides the entire migration. ## Core Features & Use Cases - Step-by-step migration path: Covers package updates, ESM or CommonJS module format selection, TypeScript configuration, schema generator changes, and client instantiation. - Driver adapter setup: Provides installation and configuration for PostgreSQL, MySQL, SQLite, SQL Server, Neon, PlanetScale, Turso, D1, and Prisma Postgres adapters. - Removed feature replacements: Shows how to replace $use middleware with Client Extensions, Prisma.validator with TypeScript satisfies, and removed CLI flags with prisma.config.ts options. - Use Case: A team upgrading a Next.js app hits "Cannot find module" errors after installing Prisma 7; this Skill walks them through setting the generator output path, creating prisma.config.ts, and wiring a PrismaPg adapter. ## Quick Start Ask the assistant to upgrade your project from Prisma 6 to Prisma 7 and fix any resulting import or connection errors.

Frequently Asked Questions about prisma-upgrade-v7

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I upgrade Prisma from v6 to v7?

Update @prisma/client and prisma to version 7, switch the generator provider to prisma-client with an explicit output path, create prisma.config.ts, install a driver adapter for your SQL database, and update PrismaClient imports to the generated client entrypoint. Then run prisma generate and test.

What driver adapter should I use with Prisma 7?

Prisma 7 requires a driver adapter matching your database: @prisma/adapter-pg for PostgreSQL and Prisma Postgres, @prisma/adapter-mariadb for MySQL, @prisma/adapter-better-sqlite3 for SQLite, and dedicated adapters for Neon, PlanetScale, Turso, D1, and SQL Server.

Does Prisma 7 support MongoDB?

No, Prisma 7 has no MongoDB connector and no MongoDB driver adapter package. MongoDB projects should stay on the latest Prisma 6.x release or migrate to Prisma Next instead of following the standard v7 SQL migration path.

Why do I get "Cannot find module" errors after upgrading Prisma?

These errors usually mean the generator output path does not match your import path, or prisma generate has not run since the schema change. Verify the output field in the generator block and regenerate the client.

How do I replace Prisma.validator in Prisma 7?

The prisma-client generator no longer exposes Prisma.validator. Use TypeScript's satisfies operator instead, for example defining a select object with satisfies Prisma.UserSelect to keep type-safe query fragments.

Can Prisma 7 work with CommonJS projects?

Yes, Prisma 7 is ESM-first but supports CommonJS by setting moduleFormat = "cjs" in the generator block. Keep your app as CommonJS, regenerate the client, and ensure tsconfig module settings agree with the generator format.