---
title: "Better Postgres with Prisma Experience"
description: "Prisma users on Neon can now use a single pooled Postgres connection string for both serverless queries and schema migrations, replacing separate pooled, direct and shadow database URLs."
url: "https://swe.quest/articles/better-postgres-with-prisma-experience-595f740758817ccf"
canonical: "https://neon.com/blog/better-postgres-with-prisma-experience"
source: "Neon"
published: "2024-03-07"
difficulty: "medium"
kind: "Announcement"
reading_minutes: 4
tags: ["postgres","schema-migrations","serverless","typescript"]
---

# Better Postgres with Prisma Experience

A post on [Neon](https://swe.quest/sources/neon.md), published 2024-03-07, 4 min read, Announcement. Original: [https://neon.com/blog/better-postgres-with-prisma-experience](https://neon.com/blog/better-postgres-with-prisma-experience)

## Summary

Prisma users on Neon can now use a single pooled Postgres connection string for both serverless queries and schema migrations, replacing separate pooled, direct and shadow database URLs. PgBouncer 1.22.0 added support for prepared statements and DISCARD ALL/DEALLOCATE ALL, which fixes the "prepared statement already exists" errors \`prisma migrate\` used to hit through the pooler, and the \`pgbouncer=true\` parameter is no longer needed. Neon also enabled role and database management via SQL, and Prisma 5.10.0 added DROP DATABASE WITH (FORCE), so \`prisma migrate dev\` can create and drop its own shadow database without manual setup.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [PostgreSQL](https://swe.quest/tags/postgres.md) (Data & databases)
- [Schema migrations](https://swe.quest/tags/schema-migrations.md) (Data & databases)
- [Serverless](https://swe.quest/tags/serverless.md) (Backend & APIs)
- [TypeScript](https://swe.quest/tags/typescript.md) (Languages)

## Prerequisites

- Postgres connection pooling ([easy posts on PostgreSQL](https://swe.quest/tags/postgres.md?difficulty=easy))
- Prisma schema files

## Keywords

Neon, Prisma, PgBouncer, Prisma Migrate, prepared statements, shadow database

## Related posts

- [Improving the developer experience for Prisma users](https://swe.quest/articles/improving-the-developer-experience-for-prisma-users-d4c8593d4e6c3e9b.md): Neon · 2023-07-13 · Medium · 4 min read · PostgreSQL, Serverless, Schema migrations, Developer tools
  Neon shipped three changes to smooth Prisma integration: faster cold starts from scale-to-zero, simultaneous pooled (PgBouncer) and direct connection strings, and SQL-based role/database management that removes the need for a manual shadow database.
- [PgBouncer is now available in Supabase](https://swe.quest/articles/pgbouncer-is-now-available-in-supabase-7611d240679e4c4c.md): Supabase · 2021-04-02 · Medium · 4 min read · PostgreSQL, Serverless, Scaling
  Supabase now bundles PgBouncer, co-located on the same server as each new project's Postgres, so serverless functions that open a connection per request don't overwhelm the database.
- [Postgres 17 is Now Available on Neon](https://swe.quest/articles/postgres-17-is-now-available-on-neon-84c88d00e9905bce.md): Neon · 2024-09-26 · Medium · 6 min read · PostgreSQL, SQL
  Postgres 17 is available on Neon for all plans, including Free, and can be provisioned in a few steps.
- [Neon Twin: How to deploy a change tested in Neon to prod in RDS](https://swe.quest/articles/neon-twin-how-to-deploy-a-change-tested-in-neon-to-prod-in-rds-09282f8f58bccb12.md): Neon · 2024-08-15 · Medium · 10 min read · Schema migrations, PostgreSQL, CI/CD, Deployment
  Schema changes tested on Neon database branches can be promoted to an AWS RDS production Postgres database through GitHub Actions that run when a pull request merges.
- [PgBouncer: The one with prepared statements](https://swe.quest/articles/pgbouncer-the-one-with-prepared-statements-cf01e34c375e84ba.md): Neon · 2024-02-15 · Medium · 4 min read · PostgreSQL, Databases, Performance engineering
  Neon now runs PgBouncer 1.22.0, which supports protocol-level prepared statements (added in 1.21.0) plus DEALLOCATE ALL and DISCARD ALL, and claims 15% to 250% higher query throughput.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
