I successfully completed the Quickstart for Prisma Postgres at https://www.prisma.io/docs/prisma-orm/quickstart/prisma-postgres.
I then tried Local development at https://www.prisma.io/docs/postgres/database/local-development. I was able to complete Step 1.
Loaded Prisma config from prisma.config.ts.
✔ Your local Prisma Postgres server default is now running 👍
🔌 To connect with Prisma ORM use the following connection strings:
DATABASE_URL="postgres://postgres:postgres@localhost:51214/template1?sslmode=disable&connection_limit=10&connect_timeout=0&max_idle_connection_lifetime=0&pool_timeout=0&socket_timeout=0"
SHADOW_DATABASE_URL="postgres://postgres:postgres@localhost:51215/template1?sslmode=disable&connection_limit=10&connect_timeout=0&max_idle_connection_lifetime=0&pool_timeout=0&socket_timeout=0"
🐘 You can also use the DATABASE_URL with the pg or postgres.js JavaScript drivers as well as your favorite DB gui.
For the best experience, set the maximum number of connections to 10, connect timeout to 0 and
idle timeout to the smallest positive value supported.
🌊 Prisma Streams is available at:
PRISMA_STREAM_URL="http://127.0.0.1:51216/v1/stream/prisma-wal"
┌─────────────────┐
│ Press q to quit │
└─────────────────┘
Note that this is different from the docs.
I'm not able to complete Step 2. I'm using the same project as that from the Quickstart, with the exception of changing the .env DATABASE_URL to that from Step 1.
Here's the console:
$ pnpm dlx prisma migrate dev
Loaded Prisma config from prisma.config.ts.
Prisma schema loaded from prisma/schema.prisma.
Datasource "db": PostgreSQL database "template1", schema "public" at "localhost:51214"
Error: P1017
Server has closed the connection. ```