Hello, is it possible to achieve something like the following using arangojs : inject a JS variable inside a comment of an AQL query?
For ex:
const myVar = "I'd like to see this in the query string, in a comment";
const query = AQL`
// FYI: ${myVar} :)
for doc in coll
(…)
`;
db.query(query);
Running the code above leads to: Uncaught ArangoError: bind parameter 'value0' was not declared in the query
Tried this too:
const myVar = "// I'd like to see this in the query string, in a comment";
const query = AQL`
${myVar}
for doc in coll
(…)
`;
db.query(query);
→ Uncaught ArangoError: syntax error, unexpected bind parameter near '@value0
Thanks,
Best regards
Hello, is it possible to achieve something like the following using arangojs : inject a JS variable inside a comment of an AQL query?
For ex:
Running the code above leads to:
Uncaught ArangoError: bind parameter 'value0' was not declared in the queryTried this too:
→
Uncaught ArangoError: syntax error, unexpected bind parameter near '@value0Thanks,
Best regards