diff --git a/e2e_tests/integration/multi-db.spec.js b/e2e_tests/integration/multi-db.spec.js
index 3d1acde3b4b..7097a34a6d7 100644
--- a/e2e_tests/integration/multi-db.spec.js
+++ b/e2e_tests/integration/multi-db.spec.js
@@ -130,5 +130,14 @@ describe('Multi database', () => {
cy.connect('neo4j', Cypress.config('password'))
cy.dropUser('noroles')
})
+ it('shows error message when trying to set a parameter on system db', () => {
+ cy.executeCommand(':clear')
+ cy.executeCommand(':use system')
+ cy.executeCommand(':param x => 1')
+ const resultFrame = cy
+ .get('[data-testid="frame"]', { timeout: 10000 })
+ .first()
+ resultFrame.should('contain', 'cannot be declared')
+ })
}
})
diff --git a/src/browser/documentation/help/param.jsx b/src/browser/documentation/help/param.jsx
index 02348247063..5c9377a4dfa 100644
--- a/src/browser/documentation/help/param.jsx
+++ b/src/browser/documentation/help/param.jsx
@@ -19,6 +19,7 @@
*/
import React from 'react'
+import ParamsOnSystemDb from './partials/params-on-systemdb'
const title = 'Set a parameter'
const subtitle = 'Set a parameter to be sent with queries.'
const category = 'cypherQueries'
@@ -46,6 +47,7 @@ const content = (
Cypher query example with a param:
MATCH (n:Person) WHERE n.name = $name
Related
diff --git a/src/browser/documentation/help/params.jsx b/src/browser/documentation/help/params.jsx index 315b93ec5a5..a05785f0496 100644 --- a/src/browser/documentation/help/params.jsx +++ b/src/browser/documentation/help/params.jsx @@ -19,6 +19,7 @@ */ import React from 'react' +import ParamsOnSystemDb from './partials/params-on-systemdb' const title = 'Parameters' const subtitle = 'View and set parameters to be sent with queries.' const category = 'cypherQueries' @@ -64,11 +65,12 @@ const content = ( {` `}{`MATCH (n:Person) WHERE n.name = $name`}
+ Related
+ A note on system database
+
+ If you are using a multi-database DBMS, parameters cannot be declared when
+ using the system database. Switch to a different database and declare,
+ then switch back to system database and use them.
+