I am trying to create a parameter from a Javascript application
But the following code doesn't work :
var input=json_table_definition.replace(/[\n\r]+/g, '');
var session = driver.session();
let results;
return session
.run(':param jsonTable=>$json_table_definition',
{json_table_definition:input}
)
.then(result => {
session.close();
})
.catch(error => {
session.close();
results=[];
throw error;
});
I get the following error in the browser:
XXXXX Uncaught (in promise) Neo4jError: Invalid input ':': expected <init> (line 1, column 1 (offset: 0))
":param jsonTable=>$json_table_definition"
^
I double checked the value in the json_table_definition parameter and it's fine The same command from the neo4j