Skip to content

Commit

Permalink
JSCBC-1092: Fix queries to default to adhoc rather than prepared.
Browse files Browse the repository at this point in the history
Motivation
----------
The 3.x SDK and SDK design guidelines describe that queries should
be adhoc by default, and should only prepare queries when explicitly
requested.

Changes
-------
Changed the adhoc value calculation to default appropriately.

Change-Id: I189c967039c824224a5b3036bef0f77a2e642a13
Reviewed-on: https://review.couchbase.org/c/couchnode/+/178493
Reviewed-by: Charles Dixon <chvckd@gmail.com>
Tested-by: Brett Lawson <brett19@gmail.com>
  • Loading branch information
brett19 committed Aug 4, 2022
1 parent d15286e commit b49d20a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/queryexecutor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ export class QueryExecutor {
{
statement: query,
client_context_id: options.clientContextId,
adhoc: options.adhoc || false,
adhoc: options.adhoc === false ? false : true,
metrics: options.metrics || false,
readonly: options.readOnly || false,
flex_index: options.flexIndex || false,
Expand Down

0 comments on commit b49d20a

Please sign in to comment.