From a4a2efa6f3de50a10393fccb6d612ecc371a7b66 Mon Sep 17 00:00:00 2001 From: Marc Hess Date: Thu, 11 Apr 2024 12:14:44 -0400 Subject: [PATCH 1/8] added tolt script (#5899) --- docusaurus.config.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index d0512acd57..4e2bba091d 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -58,6 +58,11 @@ const config: Config = { 'data-document-language': 'true', 'data-domain-script': '22c2e2c0-3df0-4958-8672-1194370ee230', }, + // Tolt script + { + src: 'https://cdn.tolt.io/tolt.js', + 'data-tolt': 'fda67739-7ed0-42d2-b716-6da0edbec191', + }, ], plugins: ['docusaurus-plugin-sass'], presets: [ From ca1d37a18193ff6b349167c02c2db992d5a56518 Mon Sep 17 00:00:00 2001 From: Marc Hess Date: Thu, 11 Apr 2024 13:29:29 -0400 Subject: [PATCH 2/8] added specfic title to index of docs (#5900) * added specfic title to index of docs * made the home page title just Prisma Documentation --- src/pages/index.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 46763fcea9..9162d645f8 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -206,10 +206,7 @@ export default function Home(): JSX.Element { siteConfig: { title }, } = useDocusaurusContext(); return ( - + From 442eeccf6dc6429c59e697156fa0ccec84435a27 Mon Sep 17 00:00:00 2001 From: Jon Harrell <4829245+jharrell@users.noreply.github.com> Date: Thu, 11 Apr 2024 13:16:43 -0600 Subject: [PATCH 3/8] move files and make sure assets are loaded from the correct path (#5886) * move files and make sure assets are loaded from the correct path. * Update docusaurus.config.ts --- content/100-getting-started/index.mdx | 24 +++++++++---------- docusaurus.config.ts | 6 ++--- src/components/GettingStarted/index.tsx | 4 +++- src/components/shortcodes/techSwitcher.tsx | 21 ++++++++-------- src/data/indexData.ts | 16 ++++++------- src/pages/index.tsx | 7 +++--- src/theme/DocBreadcrumbs/Items/Home/index.tsx | 3 +-- .../Navbar/MobileSidebar/Header/index.tsx | 2 +- src/theme/NotFound/Content/index.tsx | 3 ++- .../technologies/cockroachdbgradient.svg | 1 - static/icons/technologies/mongodbsimple.svg | 1 - static/icons/technologies/mysqlsimple.svg | 1 - static/icons/technologies/planetscale.svg | 1 - .../icons/technologies/postgresqlsimple.svg | 1 - static/icons/technologies/sqlserver.svg | 1 - 15 files changed, 45 insertions(+), 47 deletions(-) delete mode 100644 static/icons/technologies/cockroachdbgradient.svg delete mode 100644 static/icons/technologies/mongodbsimple.svg delete mode 100644 static/icons/technologies/mysqlsimple.svg delete mode 100644 static/icons/technologies/planetscale.svg delete mode 100644 static/icons/technologies/postgresqlsimple.svg delete mode 100644 static/icons/technologies/sqlserver.svg diff --git a/content/100-getting-started/index.mdx b/content/100-getting-started/index.mdx index d761ef292b..9e22b4048b 100644 --- a/content/100-getting-started/index.mdx +++ b/content/100-getting-started/index.mdx @@ -77,32 +77,32 @@ _Select one of these options if you want to connect Prisma ORM to your own datab @@ -115,32 +115,32 @@ _Select one of these options if you want to connect Prisma ORM to your own datab diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 4e2bba091d..5653ddb84a 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -14,7 +14,7 @@ const config: Config = { url: 'https://www.prisma.io', // Set the // pathname under which your site is served // For GitHub pages deployment, it is often '//' - baseUrl: DOCUSAURUS_BASE_URL ?? '/', + baseUrl: DOCUSAURUS_BASE_URL, trailingSlash: false, onBrokenLinks: 'throw', @@ -123,7 +123,7 @@ const config: Config = { }, items: [ { - to: DOCUSAURUS_BASE_URL === '/' ? DOCUSAURUS_BASE_URL : '/docs', + to: DOCUSAURUS_BASE_URL, position: 'left', label: '/docs', className: 'logo-link', @@ -233,7 +233,7 @@ const config: Config = { items: [ { label: 'Docs', - to: DOCUSAURUS_BASE_URL === '/' ? DOCUSAURUS_BASE_URL : '/docs', + to: DOCUSAURUS_BASE_URL, }, { label: 'Get started', diff --git a/src/components/GettingStarted/index.tsx b/src/components/GettingStarted/index.tsx index 5cee2ba128..8377cb8f89 100644 --- a/src/components/GettingStarted/index.tsx +++ b/src/components/GettingStarted/index.tsx @@ -3,6 +3,7 @@ import { Icon } from '../Icon' import { Tooltip } from '../tooltip/Tooltip' import styles from "../../css/gettingStarted.module.scss" import Link from '@docusaurus/Link' +import useBaseUrl from '@docusaurus/useBaseUrl' export const Database = ({ color, width, height }: any) => (
{ const squareCardRef = useRef(null) + const imgUrl = useBaseUrl(image) const [visibleTooltip, setVisibleTooltip] = useState(false) return ( <> @@ -86,7 +88,7 @@ export const SquareLogo = ({ image, tech, url }: any) => { onMouseMove={() => setVisibleTooltip(true)} onMouseLeave={() => setVisibleTooltip(false)} > - + {visibleTooltip && ( diff --git a/src/components/shortcodes/techSwitcher.tsx b/src/components/shortcodes/techSwitcher.tsx index c171dff4cc..fcc97c6751 100644 --- a/src/components/shortcodes/techSwitcher.tsx +++ b/src/components/shortcodes/techSwitcher.tsx @@ -3,6 +3,7 @@ import SelectComponent from './select' import { components } from 'react-select' import Link from '@docusaurus/Link' import styles from "./styles.module.scss" +import useBaseUrl from '@docusaurus/useBaseUrl' interface TechSwitchProps { type: string @@ -18,15 +19,15 @@ interface TechItem { } const icons = { - node: `/docs/img/technologies/nodejs.svg`, //, - typescript: `/docs/img/technologies/typescript.svg`, //, - mysql: `/docs/img/technologies/mysql.svg`, //, - postgresql: `/docs/img/technologies/postgresql.svg`, //, - sqlite: `/docs/img/technologies/sqlite.svg`, //, - mongodb: `/docs/img/technologies/mongodb.svg`, //, - sqlserver: `/docs/img/technologies/sqlserver.svg`, //, - planetscale: `/docs/img/technologies/planetscale.svg`, //, - cockroachdb: `/docs/img/technologies/cockroachdb.svg`, //, + node: `/img/technologies/nodejs.svg`, //, + typescript: `/img/technologies/typescript.svg`, //, + mysql: `/img/technologies/mysql.svg`, //, + postgresql: `/img/technologies/postgresql.svg`, //, + sqlite: `/img/technologies/sqlite.svg`, //, + mongodb: `/img/technologies/mongodb.svg`, //, + sqlserver: `/img/technologies/sqlserver.svg`, //, + planetscale: `/img/technologies/planetscale.svg`, //, + cockroachdb: `/img/technologies/cockroachdb.svg`, //, } const technologyTypes = { @@ -65,7 +66,7 @@ const TechnologySwitch = ({ type, onChangeTech, technologies, defaultTech, url, return (
- + {technologyNames[item.technology]}
diff --git a/src/data/indexData.ts b/src/data/indexData.ts index e9c0e67a7c..5ad1c5ef3b 100644 --- a/src/data/indexData.ts +++ b/src/data/indexData.ts @@ -121,49 +121,49 @@ export const ORMGeneralLinkData = [ export const DatabaseData = [ { title: 'PostgreSQL', - icon: "postgresqlsimple", + icon: "/img/technologies/postgresqlsimple.svg", darkIcon: "postgresqldark", url: '/orm/overview/databases/postgresql', }, { title: 'MySQL', - icon: "mysqlsimple", + icon: "/img/technologies/mysqlsimple.svg", darkIcon: "mysqlsimple", url: '/orm/overview/databases/mysql', }, { title: 'SQL Server', - icon: "sqlserver", + icon: "/img/technologies/sqlserver.svg", darkIcon: "sqlserver", url: '/orm/overview/databases/sql-server', }, { title: 'SQLite', - icon: "sqlite", + icon: "/img/technologies/sqlite.svg", darkIcon: "sqlite", url: '/orm/overview/databases/sqlite', }, { title: 'MongoDB', - icon: "mongodbsimple", + icon: "/img/technologies/mongodbsimple.svg", darkIcon: "mongodbsimple", url: '/orm/overview/databases/mongodb', }, { title: 'CockroachDB', - icon: "cockroachdb", + icon: "/img/technologies/cockroachdb.svg", darkIcon: "cockroachdbdark", url: '/orm/overview/databases/cockroachdb', }, { title: 'Planetscale', - icon: "planetscale", + icon: "/img/technologies/planetscale.svg", darkIcon: "planetscaledark", url: '/orm/overview/databases/planetscale', }, { title: 'MariaDB', - icon: "mariadb", + icon: "/img/technologies/mariadb.svg", darkIcon: "mariadbdark", url: '/orm/overview/databases/mysql', }, diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 9162d645f8..cf66d4e314 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -15,6 +15,7 @@ import { } from '@site/src/data/indexData'; import styles from './index.module.scss'; +import useBaseUrl from '@docusaurus/useBaseUrl'; function HomepageCard({ className, @@ -143,11 +144,11 @@ function HomepageDatabasesSection() {
{e.title} diff --git a/src/theme/DocBreadcrumbs/Items/Home/index.tsx b/src/theme/DocBreadcrumbs/Items/Home/index.tsx index 27dde06c5a..97ff0f4a4d 100644 --- a/src/theme/DocBreadcrumbs/Items/Home/index.tsx +++ b/src/theme/DocBreadcrumbs/Items/Home/index.tsx @@ -5,8 +5,7 @@ import { translate } from '@docusaurus/Translate'; import IconHome from '@theme/Icon/Home'; import styles from './styles.module.css'; export default function HomeBreadcrumbItem() { - let homeHref = useBaseUrl('/'); - homeHref = homeHref === '/' ? homeHref : '/docs' + const homeHref = useBaseUrl('/'); return (
  • - + /docs diff --git a/src/theme/NotFound/Content/index.tsx b/src/theme/NotFound/Content/index.tsx index 39c36c510b..a2ceee804b 100644 --- a/src/theme/NotFound/Content/index.tsx +++ b/src/theme/NotFound/Content/index.tsx @@ -4,12 +4,13 @@ import Translate from '@docusaurus/Translate'; import Heading from '@theme/Heading'; import Link from '@docusaurus/Link'; import styles from './styles.module.scss' +import useBaseUrl from '@docusaurus/useBaseUrl'; export default function NotFoundContent({ className }) { return (
    - +
    \ No newline at end of file diff --git a/static/icons/technologies/mongodbsimple.svg b/static/icons/technologies/mongodbsimple.svg deleted file mode 100644 index c544636f49..0000000000 --- a/static/icons/technologies/mongodbsimple.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/icons/technologies/mysqlsimple.svg b/static/icons/technologies/mysqlsimple.svg deleted file mode 100644 index 49fa851770..0000000000 --- a/static/icons/technologies/mysqlsimple.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/icons/technologies/planetscale.svg b/static/icons/technologies/planetscale.svg deleted file mode 100644 index eb481abea5..0000000000 --- a/static/icons/technologies/planetscale.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/icons/technologies/postgresqlsimple.svg b/static/icons/technologies/postgresqlsimple.svg deleted file mode 100644 index e458a949b2..0000000000 --- a/static/icons/technologies/postgresqlsimple.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/static/icons/technologies/sqlserver.svg b/static/icons/technologies/sqlserver.svg deleted file mode 100644 index 513c4cfd68..0000000000 --- a/static/icons/technologies/sqlserver.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file From a71c03040607c4b808be915d92c087ff61cfa13c Mon Sep 17 00:00:00 2001 From: Petra Donka Date: Fri, 12 Apr 2024 03:11:14 +0200 Subject: [PATCH 4/8] Fix PlanetScale capitalization (#5867) --- src/data/indexData.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/indexData.ts b/src/data/indexData.ts index 5ad1c5ef3b..c89bc726e0 100644 --- a/src/data/indexData.ts +++ b/src/data/indexData.ts @@ -156,7 +156,7 @@ export const DatabaseData = [ url: '/orm/overview/databases/cockroachdb', }, { - title: 'Planetscale', + title: 'PlanetScale', icon: "/img/technologies/planetscale.svg", darkIcon: "planetscaledark", url: '/orm/overview/databases/planetscale', From 4c9929153e52767e5c0c6240c2da2eb460443295 Mon Sep 17 00:00:00 2001 From: Ankur Datta <64993082+ankur-arch@users.noreply.github.com> Date: Fri, 12 Apr 2024 15:56:24 +0200 Subject: [PATCH 5/8] feat: modify railway docs to add enrollment pause warning (#5898) * feat: modify railway docs * Update content/400-pulse/250-database-setup/400-neon.mdx Co-authored-by: Nikolas * Update content/400-pulse/250-database-setup/400-neon.mdx Co-authored-by: Nikolas * Update content/400-pulse/250-database-setup/400-neon.mdx Co-authored-by: Nikolas --------- Co-authored-by: Nikolas --- .../400-pulse/250-database-setup/400-neon.mdx | 39 +++++++++++-------- 1 file changed, 23 insertions(+), 16 deletions(-) diff --git a/content/400-pulse/250-database-setup/400-neon.mdx b/content/400-pulse/250-database-setup/400-neon.mdx index f3a6109085..416d964558 100644 --- a/content/400-pulse/250-database-setup/400-neon.mdx +++ b/content/400-pulse/250-database-setup/400-neon.mdx @@ -6,31 +6,38 @@ tocDepth: 3 toc: true --- - +This section provides step-by-step instructions to make a [Neon](https://neon.tech/) database compatible with Prisma Pulse. -To enable logical replication in Neon for Prisma Pulse, follow these steps: +## 1. Enable logical replication on Neon - +To enable logical replication on Neon, follow these steps: -## Enable logical replication on Neon +1. Navigate to your project in the [Neon console](https://console.neon.tech/). +2. Go to the **Project settings** section from the Neon Dashboard. +3. Go to the **Beta** section in **Project Settings**. +4. Click on **Enable**. + + + You may be restricted from enabling logical replications due to an Enrollment Pause for the Neon logical replication beta phase. Learn more about enabling logical replication in Neon [here](https://neon.tech/docs/guides/logical-replication-neon#enabling-logical-replication-in-neon). + -1. Enable logical replication in Neon console: +You have successfully enabled Logical replication for Neon. Now, follow the steps below to configure your Neon database to work with Pulse. - - Navigate to your project in the Neon console. - - Access the **Project settings** from the Neon Dashboard. - - Go to the **Beta** section. - - Click on **Enable**. +## 2. Create publications in Neon - Learn more about enabling logical replication in Neon [here](https://neon.tech/docs/guides/logical-replication-neon#enabling-logical-replication-in-neon). - -2. Create publication for database events. Use the following SQL query to create a publication for all tables: +After enabling logical replication on Neon, follow these steps: +1. Create a publication to listen to database events from your Neon database. Use the **SQL Editor** in your Neon project to execute the SQL query to create a publication to listen to database change events from all tables: ```sql CREATE Publication $PUBLICATION_NAME FOR ALL TABLES; ``` - - Additionally, you can manage specific models for which you want to listen to database events in Neon. Refer to [this](/pulse/database-setup/general-database-instructions#manage-your-own-publication-slot) section for more details on managing Publications. - -3. Before enabling Prisma Pulse, make sure to provide the publication name in the Platform Console: +
    + + You can also create a publication to subscribe to database events from *specific tables*. To learn more on managing publications refer to [this](/pulse/database-setup/general-database-instructions#manage-your-own-publication-slot) section. + + +2. Before enabling Prisma Pulse, make sure to insert the publication name (e.g., `$PUBLICATION_NAME`) in the **Publication name** field in your project environment configuration for Pulse in the [Platform Console](https://pris.ly/pdp): ![](/img/pulse/replication-slot-submission.png) + +Your Neon database is now Pulse-ready! Follow our [getting started](/pulse/getting-started#21-install-the-pulse-client-extension) guide to see how to use Pulse in your application. \ No newline at end of file From 7f3af062ae1adca036c1ad12e7da60dd4b017056 Mon Sep 17 00:00:00 2001 From: Jan Piotrowski Date: Fri, 12 Apr 2024 19:19:06 +0200 Subject: [PATCH 6/8] fix(working-with-json-fields): Restructure (#4903) * fix(working-with-json-fields): Restructure * fix conflicts after docusaurus migration --------- Co-authored-by: Alex Ruheni <33921841+ruheni@users.noreply.github.com> Co-authored-by: Carla Goncalves Co-authored-by: Jon Harrell <4829245+jharrell@users.noreply.github.com> --- .../100-working-with-json-fields.mdx | 76 ++++++++++--------- .../050-client-preview-features.mdx | 2 +- .../101-jsonprotocol-changes.mdx | 2 +- 3 files changed, 44 insertions(+), 36 deletions(-) diff --git a/content/200-orm/200-prisma-client/200-special-fields-and-types/100-working-with-json-fields.mdx b/content/200-orm/200-prisma-client/200-special-fields-and-types/100-working-with-json-fields.mdx index 25a59b2a9f..63b16beea7 100644 --- a/content/200-orm/200-prisma-client/200-special-fields-and-types/100-working-with-json-fields.mdx +++ b/content/200-orm/200-prisma-client/200-special-fields-and-types/100-working-with-json-fields.mdx @@ -109,40 +109,9 @@ const createUser = await prisma.user.create({ See also: [Advanced example: Update a nested JSON key value](#advanced-example-update-a-nested-json-key-value) -## Filter on a `Json` field +## Filter on a `Json` field (simple) -From v2.23.0, you can filter rows by the data inside a `Json` type. We call this **advanced `Json` filtering**. - -The availability of advanced `Json` filtering depends on your Prisma ORM version: - -- V4.0.0 or later: advanced `Json` filtering is [generally available](/orm/more/releases#generally-available-ga). -- From v2.23.0, but before v4.0.0: advanced `Json` filtering is a [preview feature](/orm/reference/preview-features/client-preview-features). Add `previewFeatures = ["filterJson"]` to your schema. [Learn more](/orm/reference/preview-features/client-preview-features#enabling-a-prisma-client-preview-feature). -- Before v2.23.0: you can [filter on the exact `Json` field value](#filter-on-exact-field-value), but you cannot use the other features described in this section. - - - -Advanced `Json` filtering is supported by [PostgreSQL](/orm/overview/databases/postgresql) and [MySQL](/orm/overview/databases/mysql) only with different syntaxes for the `path` option. PostgreSQL does not support [filtering on object key values in arrays](#filtering-on-object-key-value-inside-array). - - - -### Database connector implementation differences - -The implementation of `Json` filtering differs between connectors: - -- The [MySQL connector](/orm/overview/databases/mysql) uses [MySQL's implementation of JSON path](https://dev.mysql.com/doc/refman/8.0/en/json.html#json-path-syntax) -- The [PostgreSQL connector](/orm/overview/databases/postgresql) uses the custom JSON functions and operators [supported in version 12 _and earlier_](https://www.postgresql.org/docs/11/functions-json.html) - -This means that `path` option syntax differs between database connectors - for example, the following is a valid MySQL `path` value: - -``` -$petFeatures.petName -``` - -The following is a valid PostgreSQL `path` value: - -``` -["petFeatures", "petName"] -``` +You can filter rows of `Json` type. ### Filter on exact field value @@ -176,9 +145,48 @@ const getUsers = await prisma.user.findMany({ }) ``` +## Filter on a `Json` field (advanced) + +You can also filter rows by the data inside a `Json` field. We call this **advanced `Json` filtering**. This functionality is supported by [PostgreSQL](/orm/overview/databases/postgresql) and [MySQL](/orm/overview/databases/mysql) only with [different syntaxes for the `path` option](#path-syntax-depending-on-database). + + + +PostgreSQL does not support [filtering on object key values in arrays](#filtering-on-object-key-value-inside-array). + + + + + +The availability of advanced `Json` filtering depends on your Prisma version: + +- v4.0.0 or later: advanced `Json` filtering is [generally available](/orm/more/releases#generally-available-ga). +- From v2.23.0, but before v4.0.0: advanced `Json` filtering is a [preview feature](/orm/reference/preview-features/client-preview-features). Add `previewFeatures = ["filterJson"]` to your schema. [Learn more](/orm/reference/preview-features/client-preview-features#enabling-a-prisma-client-preview-feature). +- Before v2.23.0: you can [filter on the exact `Json` field value](#filter-on-exact-field-value), but you cannot use the other features described in this section. + + + +### path syntax depending on database + +The filters below use a `path` option to select specific parts of the `Json` value to filter on. The implementation of that filtering differs between connectors: + +- The [MySQL connector](/orm/overview/databases/mysql) uses [MySQL's implementation of JSON path](https://dev.mysql.com/doc/refman/8.0/en/json.html#json-path-syntax) +- The [PostgreSQL connector](/orm/overview/databases/postgresql) uses the custom JSON functions and operators [supported in version 12 _and earlier_](https://www.postgresql.org/docs/11/functions-json.html) + +For example, the following is a valid MySQL `path` value: + +``` +$petFeatures.petName +``` + +The following is a valid PostgreSQL `path` value: + +``` +["petFeatures", "petName"] +``` + ### Filter on object property -In [2.23.0](https://github.com/prisma/prisma/releases/tag/2.23.0) and later, you can filter on a specific property inside a block of JSON. In the following examples, the value of `extendedPetsData` is a one-dimensional, unnested JSON object: +You can filter on a specific property inside a block of JSON. In the following examples, the value of `extendedPetsData` is a one-dimensional, unnested JSON object: ```json highlight=11;normal { diff --git a/content/200-orm/500-reference/500-preview-features/050-client-preview-features.mdx b/content/200-orm/500-reference/500-preview-features/050-client-preview-features.mdx index c3659a4fdc..453dfe484e 100644 --- a/content/200-orm/500-reference/500-preview-features/050-client-preview-features.mdx +++ b/content/200-orm/500-reference/500-preview-features/050-client-preview-features.mdx @@ -68,7 +68,7 @@ In the list below, you can find a history of Prisma Client and Prisma schema fea | [`referentialIntegrity`](/orm/prisma-schema/data-model/relations/relation-mode) | [3.1.1](https://github.com/prisma/prisma/releases/tag/3.1.1) | [4.7.0](https://github.com/prisma/prisma/releases/tag/4.7.0) | | [`interactiveTransactions`](/orm/prisma-client/queries/transactions#interactive-transactions) | [2.29.0](https://github.com/prisma/prisma/releases/tag/2.29.0) |
    • [4.7.0](https://github.com/prisma/prisma/releases/tag/4.7.0)
    • with Prisma Accelerate [5.1.1](https://github.com/prisma/prisma/releases/tag/5.1.1)
    | | [`extendedIndexes`](/orm/prisma-schema/data-model/indexes) | [3.5.0](https://github.com/prisma/prisma/releases/tag/3.5.0) | [4.0.0](https://github.com/prisma/prisma/releases/tag/4.0.0) | -| [`filterJson`](/orm/prisma-client/special-fields-and-types/working-with-json-fields#filter-on-a-json-field) | [2.23.0](https://github.com/prisma/prisma/releases/tag/2.23.0) | [4.0.0](https://github.com/prisma/prisma/releases/tag/4.0.0) | +| [`filterJson`](/orm/prisma-client/special-fields-and-types/working-with-json-fields#filter-on-a-json-field-simple) | [2.23.0](https://github.com/prisma/prisma/releases/tag/2.23.0) | [4.0.0](https://github.com/prisma/prisma/releases/tag/4.0.0) | | [`improvedQueryRaw`](/orm/prisma-client/queries/raw-database-access/raw-queries#raw-query-type-mapping) | [3.14.0](https://github.com/prisma/prisma/releases/tag/3.14.0) | [4.0.0](https://github.com/prisma/prisma/releases/tag/4.0.0) | | [`cockroachdb`](/orm/overview/databases/cockroachdb) |
    • [3.9.0](https://github.com/prisma/prisma/releases/tag/3.9.0)
    • migrations in CockroachDB in [3.11.0](https://github.com/prisma/prisma/releases/tag/3.11.0)
    | [3.14.0](https://github.com/prisma/prisma/releases/tag/3.14.0) | | [`mongodb`](/orm/overview/databases/mongodb) |
    • [2.27.0](https://github.com/prisma/prisma/releases/tag/2.27.0)
    • introspection of MongoDB in [3.2.0](https://github.com/prisma/prisma/releases/tag/3.2.0)
    • introspection of embedded documents in [3.4.0](https://github.com/prisma/prisma/releases/tag/3.4.0)
    • MongoDB embedded documents in [3.10.0](https://github.com/prisma/prisma/releases/tag/3.10.0)
    • introspection of embedded documents in [3.10.0](https://github.com/prisma/prisma/releases/tag/3.10.0)
    • raw query support for MongoDB in [3.9.0](https://github.com/prisma/prisma/releases/tag/3.9.0)
    • filters in embedded documents as an Experimental Feature in [3.11.0](https://github.com/prisma/prisma/releases/tag/3.11.0)
    • order by embedded documents in [3.11.0](https://github.com/prisma/prisma/releases/tag/3.11.0)
    | [3.12.0](https://github.com/prisma/prisma/releases/tag/3.12.0) | diff --git a/content/200-orm/800-more/300-upgrade-guides/200-upgrading-versions/600-upgrading-to-prisma-5/101-jsonprotocol-changes.mdx b/content/200-orm/800-more/300-upgrade-guides/200-upgrading-versions/600-upgrading-to-prisma-5/101-jsonprotocol-changes.mdx index a2d6ca728e..9b21076af3 100644 --- a/content/200-orm/800-more/300-upgrade-guides/200-upgrading-versions/600-upgrading-to-prisma-5/101-jsonprotocol-changes.mdx +++ b/content/200-orm/800-more/300-upgrade-guides/200-upgrading-versions/600-upgrading-to-prisma-5/101-jsonprotocol-changes.mdx @@ -167,7 +167,7 @@ prisma.user.findMany({ #### `path` argument for filtering on JSON fields in PostgreSQL -[When filtering on JSON fields in a PostgreSQL model](/orm/prisma-client/special-fields-and-types/working-with-json-fields#filter-on-a-json-field) the `path` argument now only accepts an array. +[When filtering on JSON fields in a PostgreSQL model](/orm/prisma-client/special-fields-and-types/working-with-json-fields#filter-on-a-json-field-simple) the `path` argument now only accepts an array. When using the following schema: From 67c9fbd9faf729260e35cfe90476cd0d58be4e74 Mon Sep 17 00:00:00 2001 From: Joe Marty Date: Fri, 12 Apr 2024 12:36:51 -0500 Subject: [PATCH 7/8] Clarify 02-migrate-from-sequelize docs (#5585) The instructions for renaming a relation field were not clear (since the original name of the field was already `posts`). This clarifies the key insight that the model name doesn't have to match the relation name. --- .../450-migrating-to-prisma/02-migrate-from-sequelize.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/200-orm/800-more/450-migrating-to-prisma/02-migrate-from-sequelize.mdx b/content/200-orm/800-more/450-migrating-to-prisma/02-migrate-from-sequelize.mdx index 5fb2d8e501..df91ff2be5 100644 --- a/content/200-orm/800-more/450-migrating-to-prisma/02-migrate-from-sequelize.mdx +++ b/content/200-orm/800-more/450-migrating-to-prisma/02-migrate-from-sequelize.mdx @@ -551,7 +551,7 @@ As opposed to the current snake_case notation of Prisma models, Prisma ORM's nam You can adjust the naming by _mapping_ the Prisma model and field names to the existing table and column names in the underlying database using `@@map` and `@map`. -Also note that you can rename [relation fields](/orm/prisma-schema/data-model/relations#relation-fields) to optimize the Prisma Client API that you'll use later to send queries to your database. For example, the `post` field on the `user` model is a _list_, so a better name for this field would be `posts` to indicate that it's plural. +Also note that you can rename [relation fields](/orm/prisma-schema/data-model/relations#relation-fields) to optimize the Prisma Client API that you'll use later to send queries to your database. For example, although we are singularizing the `Posts` model name to `Post`, the `posts` field on the `user` model is a _list_, so it makes sense to keep that named `posts` to indicate that it's plural. Sequelize generates a `SequelizeMeta` model that is used internally by the library that is not needed. Therefore, you'll manually delete it from the schema. From 19e82c3bb7305248a03c0e8b05ba9f3dc50587d8 Mon Sep 17 00:00:00 2001 From: Nitin Gupta Date: Fri, 12 Apr 2024 20:16:24 +0200 Subject: [PATCH 8/8] Removed reference to Slack (#5903) --- .../04-upgrading-nexus-prisma-to-nexus.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/200-orm/800-more/300-upgrade-guides/800-upgrade-from-prisma-1/04-upgrading-nexus-prisma-to-nexus.mdx b/content/200-orm/800-more/300-upgrade-guides/800-upgrade-from-prisma-1/04-upgrading-nexus-prisma-to-nexus.mdx index 670246349b..9b5979914a 100644 --- a/content/200-orm/800-more/300-upgrade-guides/800-upgrade-from-prisma-1/04-upgrading-nexus-prisma-to-nexus.mdx +++ b/content/200-orm/800-more/300-upgrade-guides/800-upgrade-from-prisma-1/04-upgrading-nexus-prisma-to-nexus.mdx @@ -6,7 +6,7 @@ metaDescription: 'Learn how to upgrade existing Prisma 1 projects with nexus-pri ## Overview -> **Note**: This guide is not fully up-to-date as it currently uses the [deprecated](https://github.com/graphql-nexus/nexus-plugin-prisma/issues/1039) version of the [`nexus-plugin-prisma`](https://github.com/graphql-nexus/nexus-plugin-prisma). While this is still functional, it is recommended to use the new [`nexus-prisma`](https://github.com/prisma/nexus-prisma/) library or an alternative code-first GraphQL library like [Pothos](https://pothos-graphql.dev/) going forward. If you have any questions, feel free to drop them in the [`#prisma1-community`](https://app.slack.com/client/T0MQBS8JG/C0152UA4DH9) channel in the [Prisma Slack](https://slack.prisma.io). +> **Note**: This guide is not fully up-to-date as it currently uses the [deprecated](https://github.com/graphql-nexus/nexus-plugin-prisma/issues/1039) version of the [`nexus-plugin-prisma`](https://github.com/graphql-nexus/nexus-plugin-prisma). While this is still functional, it is recommended to use the new [`nexus-prisma`](https://github.com/prisma/nexus-prisma/) library or an alternative code-first GraphQL library like [Pothos](https://pothos-graphql.dev/) going forward. If you have any questions, feel free to share them on our [Discord](https://pris.ly/discord). This upgrade guide describes how to upgrade a project that's based on [Prisma 1](https://github.com/prisma/prisma1) and uses [`nexus`](https://www.npmjs.com/package/nexus) (< v0.12.0) or [`@nexus/schema`](https://github.com/graphql-nexus/schema) together with [`nexus-prisma`](https://www.npmjs.com/package/nexus-prisma) (< v4.0.0) to implement a GraphQL server.