Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Notice that the install command automatically invokes `prisma generate` for you

![Install and generate Prisma Client](../../../images/prisma-client-install-and-generate.png)

Whenever you make changes to your Prisma schema in the future, you manually need to invoke `prisma generate` in order to accommodate the changes in your Prisma Client API.
Whenever you update your Prisma schema, you will have to update your database schema using either `prisma migrate dev` or `prisma db push`. This will keep your database schema in sync with your Prisma schema. The commands will also regenerate Prisma Client.

<SwitchTech technologies={['node', 'postgresql']}>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Notice that the install command automatically invokes `prisma generate` for you

![Install and generate Prisma Client](./../../../images/prisma-client-install-and-generate.png)

Whenever you make changes to your Prisma schema in the future, you manually need to invoke `prisma generate` in order to accommodate the changes in your Prisma Client API.
Whenever you update your Prisma schema, you will need to run the `prisma db push` command to create new indexes and regenerate Prisma Client.

<SwitchTech technologies={['node', 'mongodb']}>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ DATABASE_URL="postgresql://johndoe:randompassword@localhost:5432/mydb?schema=pub

You now need to adjust the connection URL to point to your own database.

<h3 id="connection-url">Connection URL</h3>

The [format of the connection URL](/reference/database-reference/connection-urls) for your database depends on the database you use. For PostgreSQL, it looks as follows (the parts spelled all-uppercased are _placeholders_ for your specific connection details):

```no-lines
Expand Down Expand Up @@ -78,6 +80,8 @@ DATABASE_URL="mysql://johndoe:randompassword@localhost:3306/mydb"

You now need to adjust the connection URL to point to your own database.

<h3 id="connection-url">Connection URL</h3>

The [format of the connection URL](/reference/database-reference/connection-urls) for your database typically depends on the database you use. For MySQL, it looks as follows (the parts spelled all-uppercased are _placeholders_ for your specific connection details):

```no-lines
Expand Down Expand Up @@ -141,6 +145,8 @@ DATABASE_URL="mysql://janedoe:mypassword@server.us-east-2.psdb.cloud/mydb?sslacc

You now need to adjust the connection URL to point to your own database.

<h3 id="connection-url">Connection URL</h3>

The [format of the connection URL](/reference/database-reference/connection-urls) for your database typically depends on the database you use. PlanetScale uses the MySQL connection URL format, which has the following structure (the parts spelled all-uppercased are _placeholders_ for your specific connection details):

```no-lines
Expand Down Expand Up @@ -223,6 +229,8 @@ datasource db {

The `url` is [set via an environment variable](/guides/development-environment/environment-variables) which is defined in `.env`. You now need to adjust the connection URL to point to your own database.

<h3 id="connection-url">Connection URL</h3>

The [format of the connection URL](/reference/database-reference/connection-urls) for your database depends on the database you use. CockroachDB uses the PostgreSQL connection URL format, which has the following structure (the parts spelled all-uppercased are _placeholders_ for your specific connection details):

```no-lines
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,13 @@ node index.js

</SwitchTech>

This will print an array of `User` records as plain old JavaScript objects.
If you created a database using the schema from the database introspection step, the query should print an empty array because there are no `User` records in the database yet.

```no-copy
[]
```

If you introspected an existing database with records, the query should return an array of JavaScript objects.

## Write data into the database

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,7 @@ node index.js

</SwitchTech>

This should print an empty array because there are no `User` records in the database yet:

```json no-lines
[]
```
If you introspected an existing database with records, the query should return an array of JavaScript objects.

## Write data into the database

Expand Down