Skip to content

Commit 06e2d57

Browse files
authored
Update src/content/docs/hyperdrive/examples/connect-to-postgres/postgres-database-providers/prisma-postgres.mdx
1 parent 867ac7f commit 06e2d57

File tree

1 file changed

+6
-3
lines changed
  • src/content/docs/hyperdrive/examples/connect-to-postgres/postgres-database-providers

1 file changed

+6
-3
lines changed

src/content/docs/hyperdrive/examples/connect-to-postgres/postgres-database-providers/prisma-postgres.mdx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,12 @@ You can connect Hyperdrive to any existing Prisma Postgres database by using you
2121
1. Go to the [**Prisma Data Platform Console**](https://console.prisma.io/) and select the project (database) you wish to connect to.
2222
2. Select **Connect to your database** > **Any client**.
2323
3. Select **Generate database credentials**. Copy the connection string for your Prisma Postgres database.
24-
4. You must append **`postgres`** as the database in your connection string. Ensure the connection string includes the necessary credentials according to the format documented below:
25-
```txt
26-
postgres://USERNAME:PASSWORD@HOSTNAME_OR_IP_ADDRESS:PORT/database_name
24+
4. Edit the connection string to make it compatible with Hyperdrive.
25+
- Add the database name after the port, but before `?sslmode=require`.
26+
- The final string will look like:
27+
28+
```txt ins="database_name"
29+
postgres://<CONNECTION_STRING>/database_name/?sslmode=require
2730
```
2831

2932
With the connection string, you can now create a Hyperdrive database configuration.

0 commit comments

Comments
 (0)