prisma-database-setup

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

Updated Jul 21, 2026
One-click install
npx skills add https://github.com/8ReTid8/vitural_reality_test --skill prisma-database-setup-8retid8
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-database-setup
Source: https://github.com/8ReTid8/vitural_reality_test/tree/main/my-app/.windsurf/skills/prisma-database-setup
Command: npx skills add https://github.com/8ReTid8/vitural_reality_test --skill prisma-database-setup-8retid8

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 workflow is error-prone, especially with the differences between Prisma 6 and Prisma 7. This Skill provides verified, provider-specific configuration guides so you avoid misconfigured schemas and broken client setups. ## Core Features & Use Cases - Provider-Specific Guides: Step-by-step setup for PostgreSQL, MySQL, SQLite, MongoDB, SQL Server, CockroachDB, and Prisma Postgres, including schema, config, and environment variable templates. - Driver Adapter Setup: Correct adapter and driver pairings (e.g., @prisma/adapter-pg with pg, @prisma/adapter-mariadb with mariadb) with instantiation examples for Prisma Client. - Version Guidance: Clear rules for MongoDB projects to stay on Prisma 6.x and avoid the unsupported Prisma 7 SQL adapter path. - Use Case: You are migrating a Node.js app from SQLite to PostgreSQL. Use this Skill to update the datasource provider, rewrite the connection string, install @prisma/adapter-pg, and regenerate Prisma Client correctly. ## Quick Start Ask the AI to configure Prisma for your database, for example: set up Prisma with PostgreSQL using a 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 the datasource provider to postgresql in schema.prisma, define the DATABASE_URL in prisma.config.ts, and install @prisma/adapter-pg with pg. Then instantiate PrismaClient with the PrismaPg adapter and run npx prisma generate.

How do I set up Prisma with MongoDB?

Stay on the latest Prisma 6.x release, use provider mongodb with prisma-client-js, and keep the connection URL in schema.prisma. Do not apply the Prisma 7 SQL adapter workflow, and ensure your MongoDB instance is a replica set for transactions.

Which Prisma driver adapter should I use for MySQL?

Use @prisma/adapter-mariadb with the mariadb driver for MySQL or MariaDB. Install both packages and pass a PrismaMariaDb adapter instance to PrismaClient with your host, port, user, password, and database.

Does Prisma 7 support MongoDB?

Prisma 7 does not provide a supported MongoDB upgrade path. MongoDB projects should remain on the latest Prisma 6.x release with prisma-client-js and prisma db push instead of migrations.

Why does Prisma Client generation fail after schema changes?

Prisma Client must be regenerated after every schema change using npx prisma generate. Also verify the generator block uses prisma-client with an explicit output path, since it does not generate into node_modules by default.

What are the limitations of SQLite with Prisma?

SQLite does not support enums or scalar lists like String[], and write operations lock the database file. Use @prisma/adapter-better-sqlite3 for local files or @prisma/adapter-libsql for Turso and edge deployments.