diff options
author | drh <drh@noemail.net> | 2018-12-24 20:21:06 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2018-12-24 20:21:06 +0000 |
commit | bd462bcc10bb1545d39359ff29cb521819ab656d (patch) | |
tree | fca095cfaad919a152ed5c1a89fa5d8937a1b789 /src/wherecode.c | |
parent | a599e150caa88cfc9a7c27cf7bd79fe93b8ea7d8 (diff) | |
download | sqlite-bd462bcc10bb1545d39359ff29cb521819ab656d.tar.gz sqlite-bd462bcc10bb1545d39359ff29cb521819ab656d.zip |
Improvements to EXPLAIN QUERY PLAN formatting. The MULTI-INDEX OR now shows
a separate "INDEX" subtree for each index. SCALAR SUBQUERY entries provide
a subquery number that is related back to the .selecttrace output.
FossilOrigin-Name: 7153552bac51295c56a1c42ca79d57195851e232509f9e9610375692f48c7e86
Diffstat (limited to 'src/wherecode.c')
-rw-r--r-- | src/wherecode.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/wherecode.c b/src/wherecode.c index d238efdc8..f7cfc4318 100644 --- a/src/wherecode.c +++ b/src/wherecode.c @@ -213,6 +213,7 @@ int sqlite3WhereExplainOneScan( } #endif zMsg = sqlite3StrAccumFinish(&str); + sqlite3ExplainBreakpoint("",zMsg); ret = sqlite3VdbeAddOp4(v, OP_Explain, sqlite3VdbeCurrentAddr(v), pParse->addrExplain, 0, zMsg,P4_DYNAMIC); } @@ -1951,6 +1952,7 @@ Bitmask sqlite3WhereCodeOneLoopStart( pOrExpr = pAndExpr; } /* Loop through table entries that match term pOrTerm. */ + ExplainQueryPlan((pParse, 1, "INDEX %d", ii+1)); WHERETRACE(0xffff, ("Subplan for OR-clause:\n")); pSubWInfo = sqlite3WhereBegin(pParse, pOrTab, pOrExpr, 0, 0, wctrlFlags, iCovCur); @@ -2054,6 +2056,7 @@ Bitmask sqlite3WhereCodeOneLoopStart( /* Finish the loop through table entries that match term pOrTerm. */ sqlite3WhereEnd(pSubWInfo); + ExplainQueryPlanPop(pParse); } } } |