File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
src/content/docs/hyperdrive Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ Hyperdrive accepts the combination of these parameters in the common connection
107107<Tabs >
108108 <TabItem label = " PostgreSQL" >
109109 ``` txt
110-
110+
111111 postgres://USERNAME:PASSWORD@HOSTNAME_OR_IP_ADDRESS:PORT/database_name
112112
113113 ```
@@ -292,11 +292,11 @@ export default {
292292 // Create a connection using the mysql2 driver (or any support driver, ORM or query builder)
293293 // with the Hyperdrive credentials. These credentials are only accessible from your Worker.
294294 const connection = await createConnection ({
295- host: env .DB_HOST ,
296- user: env .DB_USER ,
297- password: env .DB_PASSWORD ,
298- database: env .DB_NAME ,
299- port: env .DB_PORT
295+ host: env .HYPERDRIVE . host ,
296+ user: env .HYPERDRIVE . user ,
297+ password: env .HYPERDRIVE . password ,
298+ database: env .HYPERDRIVE . database ,
299+ port: env .HYPERDRIVE . port
300300
301301 // The following line is needed for mysql2 compatibility with Workers
302302 // mysql2 uses eval() to optimize result parsing for rows with > 100 columns
You can’t perform that action at this time.
0 commit comments