diff --git a/Documentation/Books/Users/Aql/Invoke.mdpp b/Documentation/Books/Users/Aql/Invoke.mdpp index d058751fd9..f7073b7df0 100644 --- a/Documentation/Books/Users/Aql/Invoke.mdpp +++ b/Documentation/Books/Users/Aql/Invoke.mdpp @@ -264,7 +264,7 @@ arangosh> stmt.explain({ allPlans: true }).plans.length; 2 ``` -To see the minified version of the plan: +To see a slightly more compact version of the plan, the following transformation can be applied: ``` arangosh> stmt.explain({ allPlans: true }).plans.map(function(plan) { return formatPlan(plan); }); @@ -292,6 +292,19 @@ arangosh> stmt.explain({ allPlans: true }).plans.map(function(plan) { return for ] ``` +`explain` will also accept the following additional options: +- *maxPlans*: limits the maximum number of plans that are created by the AQL query optimizer +- *optimizer.rules*: a list of to-be-included or to-be-excluded optimizer rules + can be put into this attribute, telling the optimizer to include or exclude + specific rules. To disable a rule, prefix its name with a `-`, to enable a rule, prefix it + with a `+`. There is also a pseudo-rule `all`, which will match all optimizer rules. + +The following example disables all optimizer rules but `remove-redundant-calculations`: + +``` +arangosh> stmt.explain({ optimizer: { rules: [ "-all", "+remove-redundant-calculations" ] } }); +``` + !SECTION Parsing queries Clients can use ArangoDB to check if a given AQL query is syntactically valid. ArangoDB provides diff --git a/Documentation/Books/Users/localtheme/templates/book/includes/summary.html b/Documentation/Books/Users/localtheme/templates/book/includes/summary.html index 81a55ec183..eac01df05c 100644 --- a/Documentation/Books/Users/localtheme/templates/book/includes/summary.html +++ b/Documentation/Books/Users/localtheme/templates/book/includes/summary.html @@ -65,7 +65,7 @@ {{ articles(summary.chapters) }} - +