prisma-database-setup

Configure Prisma ORM with PostgreSQL, MySQL, SQLite, MongoDB, and other database providers.

Updated May 23, 2026
One-click install
npx skills add https://github.com/kveperedo/website --skill prisma-database-setup-kveperedo
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-database-setup
Source: https://github.com/kveperedo/website/tree/main/.agents/skills/prisma-database-setup
Command: npx skills add https://github.com/kveperedo/website --skill prisma-database-setup-kveperedo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Setting up Prisma with the correct database provider, connection string format, driver adapter, and client generation steps is error-prone, especially with the differences between Prisma 6 and Prisma 7 workflows. This Skill provides verified, provider-specific configuration guides so you avoid misconfigured schemas, wrong adapters, and connection failures. ## Core Features & Use Cases - Provider-Specific Guides: Step-by-step setup for PostgreSQL, MySQL, SQLite, MongoDB, SQL Server, CockroachDB, and Prisma Postgres, including schema blocks, prisma.config.ts, and environment variables. - Driver Adapter Selection: Maps each database to the correct @prisma/adapter-* package and underlying JS driver, with instantiation examples. - Version Boundary Guidance: Clarifies that MongoDB projects should stay on Prisma 6.x with prisma-client-js and must not follow the Prisma 7 SQL adapter workflow. - Use Case: You are migrating an app from SQLite to PostgreSQL. Use this Skill to update the datasource provider, install @prisma/adapter-pg, set the DATABASE_URL format, and regenerate Prisma Client correctly. ## Quick Start Ask the AI to configure Prisma 7 with PostgreSQL using the pg driver adapter and generate the client.

Frequently Asked Questions about prisma-database-setup

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

FAQPage Schema
How do I configure Prisma with PostgreSQL?▼

Set provider = "postgresql" in prisma/schema.prisma, define the datasource URL in prisma.config.ts, and set DATABASE_URL in .env. Install @prisma/adapter-pg and pg, then instantiate PrismaClient with the PrismaPg adapter.

Which Prisma driver adapter should I use for my database?▼

PostgreSQL, CockroachDB, and Prisma Postgres use @prisma/adapter-pg with pg; MySQL uses @prisma/adapter-mariadb; SQLite uses @prisma/adapter-better-sqlite3 or @prisma/adapter-libsql for Turso; SQL Server uses @prisma/adapter-mssql.

Does Prisma 7 support MongoDB?▼

MongoDB projects should stay on the latest Prisma 6.x release with prisma-client-js and keep the URL in schema.prisma. The Prisma 7 SQL adapter workflow does not provide a supported MongoDB upgrade path.

Why does Prisma fail to connect to my database?▼

Common causes include wrong host or port, firewall rules, unencoded special characters in passwords, and a missing schema parameter in the URL. Verify the database is running and the connection string format matches your provider.

What are the limitations of SQLite with Prisma?▼

SQLite does not support enums or scalar list types like String[], and write operations lock the database file. It suits local development but not high-concurrency production workloads.

How do I set up Prisma with PlanetScale MySQL?▼

PlanetScale does not support foreign key constraints, so set relationMode = "prisma" in the datasource block to emulate relations in Prisma. Otherwise follow the standard MySQL setup with the MariaDB adapter.