Prompt Buddy logoPrompt Buddy

prisma · Prisma Docs

Drizzle (/docs/guides/switch-to-prisma-orm/from-drizzle)

A guide providing migration paths for transitioning from Mongoose or SQL-based ORMs like Sequelize and TypeORM to Prisma ORM.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

Drizzle (/docs/guides/switch-to-prisma-orm/from-drizzle)

A guide providing migration paths for transitioning from Mongoose or SQL-based ORMs like Sequelize and TypeORM to Prisma ORM.

When To Use

Use when migrating an existing application from Mongoose, Sequelize, or TypeORM to Prisma ORM.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/prisma-drizzle-docs-guides-switch-to-orm-from-workflow-guide.mdA guide detailing the process and considerations for migrating from Drizzle ORM to Prisma ORM.Questions about a guide detailing the process and considerations for migrating from Drizzle ORM to Prisma ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle.bashBash commands to install Prisma, the Prisma client, and the PostgreSQL adapter for migrating from Drizzle.Exact payloads, commands, or snippets shown in Bash commands to install Prisma, the Prisma client, and the PostgreSQL adapter for migrating from Drizzle.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-2.bashBash commands to install Prisma, PostgreSQL types, and the Prisma client with the PostgreSQL adapter.Exact payloads, commands, or snippets shown in Bash commands to install Prisma, PostgreSQL types, and the Prisma client with the PostgreSQL adapter.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-3.bashBash commands to install Prisma, Prisma Client, and the PostgreSQL adapter to begin migrating from Drizzle.Exact payloads, commands, or snippets shown in Bash commands to install Prisma, Prisma Client, and the PostgreSQL adapter to begin migrating from Drizzle.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-docs-switch-from-dr.bashBash commands to install Prisma, PostgreSQL types, and the Prisma client using the Bun package manager.Exact payloads, commands, or snippets shown in Bash commands to install Prisma, PostgreSQL types, and the Prisma client using the Bun package manager.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-init-directory.bashA bash command demonstrating how to initialize a Prisma project with a specific output directory for the generated client.Exact payloads, commands, or snippets shown in A bash command demonstrating how to initialize a Prisma project with a specific output directory for the generated cl...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-init-directory-2.bashA bash command to initialize a Prisma project and specify a custom output directory for the generated client.Exact payloads, commands, or snippets shown in A bash command to initialize a Prisma project and specify a custom output directory for the generated client.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-init-directory-3.bashA bash command to initialize a Prisma project and specify a custom output directory for the generated client.Exact payloads, commands, or snippets shown in A bash command to initialize a Prisma project and specify a custom output directory for the generated client.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-init-drizzle-migrat.bashA bash command using bunx to initialize Prisma with a specific output directory during a migration from Drizzle.Exact payloads, commands, or snippets shown in A bash command using bunx to initialize Prisma with a specific output directory during a migration from Drizzle.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration.prismaA Prisma schema file demonstrating the configuration used when migrating from Drizzle ORM to Prisma.Exact payloads, commands, or snippets shown in A Prisma schema file demonstrating the configuration used when migrating from Drizzle ORM to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-d.prismaA Prisma schema file demonstrating the datasource configuration required when migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A Prisma schema file demonstrating the datasource configuration required when migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-d-2.prismaA Prisma schema configuration defining a MySQL datasource for migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A Prisma schema configuration defining a MySQL datasource for migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-s.prismaA Prisma datasource configuration block specifically configured for a SQL Server database to facilitate migration from Drizzle ORM.Exact payloads, commands, or snippets shown in A Prisma datasource configuration block specifically configured for a SQL Server database to facilitate migration fro...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-s-2.prismaA Prisma schema file demonstrating a SQLite datasource configuration used when migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A Prisma schema file demonstrating a SQLite datasource configuration used when migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-c.typescriptA TypeScript configuration file demonstrating how to set up Prisma migrations when transitioning from a Drizzle ORM setup.Exact payloads, commands, or snippets shown in A TypeScript configuration file demonstrating how to set up Prisma migrations when transitioning from a Drizzle ORM s...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-4.bashBash commands for installing dotenv and other necessary dependencies when migrating from Drizzle to Prisma.Exact payloads, commands, or snippets shown in Bash commands for installing dotenv and other necessary dependencies when migrating from Drizzle to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-5.bashA bash command to install the dotenv package as part of the migration from Drizzle to Prisma.Exact payloads, commands, or snippets shown in A bash command to install the dotenv package as part of the migration from Drizzle to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-6.bashA bash command to install the dotenv package using yarn as part of the migration from Drizzle to Prisma.Exact payloads, commands, or snippets shown in A bash command to install the dotenv package using yarn as part of the migration from Drizzle to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-7.bashA bash command to install the dotenv package using the bun package manager as part of the migration from Drizzle to Prisma.Exact payloads, commands, or snippets shown in A bash command to install the dotenv package using the bun package manager as part of the migration from Drizzle to P...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-db-pull-from-drizzl.bashA bash command to introspect an existing database schema populated by Drizzle ORM using the Prisma CLI.Exact payloads, commands, or snippets shown in A bash command to introspect an existing database schema populated by Drizzle ORM using the Prisma CLI.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-db-pull-from-drizzl-2.bashA bash command to introspect an existing database schema using Prisma CLI after migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to introspect an existing database schema using Prisma CLI after migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-db-pull-from-drizzl-3.bashA bash command to introspect an existing database schema using Prisma CLI after migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to introspect an existing database schema using Prisma CLI after migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-db-pull-bunx-comman.bashA bash command using bunx to execute the prisma db pull operation.Exact payloads, commands, or snippets shown in A bash command using bunx to execute the prisma db pull operation.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-2.prismaA Prisma schema model representing a Drizzle ORM table structure to demonstrate migration patterns.Exact payloads, commands, or snippets shown in A Prisma schema model representing a Drizzle ORM table structure to demonstrate migration patterns.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-8.bashA bash command to create the initial Prisma migrations directory structure when migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to create the initial Prisma migrations directory structure when migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-diff-drizzl.bashA bash command that uses prisma migrate diff to generate a SQL migration script by comparing an empty state to an existing Prisma schema.Exact payloads, commands, or snippets shown in A bash command that uses prisma migrate diff to generate a SQL migration script by comparing an empty state to an exi...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-diff-drizzl-2.bashA bash command using prisma migrate diff to generate a SQL migration script from a Prisma schema starting from an empty state.Exact payloads, commands, or snippets shown in A bash command using prisma migrate diff to generate a SQL migration script from a Prisma schema starting from an emp...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-diff-drizzl-3.bashA bash command using prisma migrate diff to generate a SQL migration script from an empty state to a Prisma schema to facilitate switching from Drizzle.Exact payloads, commands, or snippets shown in A bash command using prisma migrate diff to generate a SQL migration script from an empty state to a Prisma schema to...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-diff-drizzl-4.bashA bash command using prisma migrate diff to generate a SQL migration script from an empty state to a Prisma schema for users switching from Drizzle.Exact payloads, commands, or snippets shown in A bash command using prisma migrate diff to generate a SQL migration script from an empty state to a Prisma schema fo...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-resolve-app.bashA bash command to manually mark a Drizzle-managed migration as applied in the Prisma migration history.Exact payloads, commands, or snippets shown in A bash command to manually mark a Drizzle-managed migration as applied in the Prisma migration history.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-resolve-app-2.bashA bash command to manually mark a Drizzle migration as applied using the Prisma CLI.Exact payloads, commands, or snippets shown in A bash command to manually mark a Drizzle migration as applied using the Prisma CLI.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-resolve-app-3.bashA bash command to resolve a Prisma migration by marking the initial Drizzle migration as applied.Exact payloads, commands, or snippets shown in A bash command to resolve a Prisma migration by marking the initial Drizzle migration as applied.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-migrate-resolve-app-4.bashA bash command to resolve a Prisma migration by marking a specific migration name as already applied when switching from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to resolve a Prisma migration by marking a specific migration name as already applied when switching f...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-3.prismaA Prisma schema model definition representing a Todo entity used to demonstrate migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A Prisma schema model definition representing a Todo entity used to demonstrate migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-generate-command-dr.bashA bash command to generate the Prisma client after migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to generate the Prisma client after migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-generate-command.bashA bash command to execute the prisma generate process using pnpm dlx.Exact payloads, commands, or snippets shown in A bash command to execute the prisma generate process using pnpm dlx.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-generate-command-dr-2.bashA bash command to run the prisma generate process when migrating from Drizzle ORM.Exact payloads, commands, or snippets shown in A bash command to run the prisma generate process when migrating from Drizzle ORM.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-generate-bunx-comma.bashA bash command using bunx to run the prisma generate operation.Exact payloads, commands, or snippets shown in A bash command using bunx to run the prisma generate operation.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-docs-switch-from-dr-2.bashA bash command to create the db/prisma.ts file as part of the migration from Drizzle to Prisma.Exact payloads, commands, or snippets shown in A bash command to create the db/prisma.ts file as part of the migration from Drizzle to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-p.tsA TypeScript implementation demonstrating how to use the PrismaPg adapter to connect Prisma to a PostgreSQL database previously managed by Drizzle.Exact payloads, commands, or snippets shown in A TypeScript implementation demonstrating how to use the PrismaPg adapter to connect Prisma to a PostgreSQL database...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle.tsA TypeScript code snippet demonstrating how to transition from Drizzle ORM database queries to Prisma ORM syntax.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to transition from Drizzle ORM database queries to Prisma ORM syntax.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-t.tsA TypeScript code snippet demonstrating how to replace Drizzle ORM queries with Prisma client methods.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to replace Drizzle ORM queries with Prisma client methods.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-2.tsA TypeScript code snippet demonstrating how to convert a Drizzle ORM insert operation using Next.js revalidatePath into a Prisma ORM equivalent.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to convert a Drizzle ORM insert operation using Next.js revalidatePath in...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-3.tsA TypeScript code snippet demonstrating how to replace a Drizzle database operation with a Prisma create call within a Next.js Server Action using revalidatePath.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to replace a Drizzle database operation with a Prisma create call within...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-guides-switch-from-.tsA TypeScript code example demonstrating Drizzle ORM syntax for deleting a todo record using the eq operator.Exact payloads, commands, or snippets shown in A TypeScript code example demonstrating Drizzle ORM syntax for deleting a todo record using the eq operator.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-4.tsA TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client calls within a Next.js server action using revalidatePath.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client calls within a Next.js se...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-guides-switch-from--2.tsA TypeScript code snippet demonstrating a Drizzle ORM update operation using eq and not functions.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating a Drizzle ORM update operation using eq and not functions.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-docs-switch-from-dr.tsA TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client calls within a Next.js Server Action using revalidatePath.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client calls within a Next.js Se...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-switch-from-drizzle-5.tsA TypeScript code snippet demonstrating a Drizzle ORM update operation used as a reference for migrating to Prisma.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating a Drizzle ORM update operation used as a reference for migrating to Prisma.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-n.tsA TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client updates within a Next.js server action using revalidatePath.Exact payloads, commands, or snippets shown in A TypeScript code snippet demonstrating how to replace Drizzle ORM logic with Prisma client updates within a Next.js...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-drizzle-orm-pg-definition.tsA TypeScript definition of a PostgreSQL schema using Drizzle ORM including posts, categories, and a many-to-many join table.Exact payloads, commands, or snippets shown in A TypeScript definition of a PostgreSQL schema using Drizzle ORM including posts, categories, and a many-to-many join...
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-4.prismaA Prisma schema file demonstrating a model structure equivalent to a Drizzle ORM configuration for migrating data.Exact payloads, commands, or snippets shown in A Prisma schema file demonstrating a model structure equivalent to a Drizzle ORM configuration for migrating data.
examples/prisma-drizzle-docs-guides-switch-to-orm-from-prisma-drizzle-migration-5.prismaA Prisma schema model definition representing a Drizzle ORM schema structure for migration purposes.Exact payloads, commands, or snippets shown in A Prisma schema model definition representing a Drizzle ORM schema structure for migration purposes.

What This Skill Covers

    • Mongoose: Learn how to migrate from Mongoose to Prisma ORM - SQL ORMs: Learn how to migrate from Sequelize or TypeORM to Prisma ORM
  • Main sections: Related pages.

Workflow

  1. Open the most relevant file under docs/ for the exact documented workflow and wording.
  2. Open schemas/ files for exact structured contracts.
  3. Open examples/ files for concrete requests, commands, snippets, and manifests.
  4. Do not add behavior or configuration that is not present in the attached source files.

Canonical source: https://www.prisma.io/docs/guides/switch-to-prisma-orm/from-drizzle