aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2018-04-23 17:09:58 +0000
committerdrh <drh@noemail.net>2018-04-23 17:09:58 +0000
commit1bddf23b89f8263d21db2e7ef1ef5a976ab1b400 (patch)
tree7a05d2c3d29bec7bd4908130e2fb389b058b451d /src
parentb3b0d317e0dbb05084480cc515135bb60839d173 (diff)
downloadsqlite-1bddf23b89f8263d21db2e7ef1ef5a976ab1b400.tar.gz
sqlite-1bddf23b89f8263d21db2e7ef1ef5a976ab1b400.zip
Do not restore the iSelectId value until after the last SELECTTRACE when
debugging Select processing. FossilOrigin-Name: 8088d8cac317adb96e357a8f4a196d7c1e0115af9c2335f167b4d7e7154299b0
Diffstat (limited to 'src')
-rw-r--r--src/select.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/select.c b/src/select.c
index a48355a9e..3a7a4eb85 100644
--- a/src/select.c
+++ b/src/select.c
@@ -5486,10 +5486,10 @@ int sqlite3Select(
*/
if( p->pPrior ){
rc = multiSelect(pParse, p, pDest);
- explainSetInteger(pParse->iSelectId, iRestoreSelectId);
#if SELECTTRACE_ENABLED
SELECTTRACE(1,pParse,p,("end compound-select processing\n"));
#endif
+ explainSetInteger(pParse->iSelectId, iRestoreSelectId);
return rc;
}
#endif
@@ -6274,12 +6274,12 @@ int sqlite3Select(
** successful coding of the SELECT.
*/
select_end:
- explainSetInteger(pParse->iSelectId, iRestoreSelectId);
sqlite3ExprListDelete(db, pMinMaxOrderBy);
sqlite3DbFree(db, sAggInfo.aCol);
sqlite3DbFree(db, sAggInfo.aFunc);
#if SELECTTRACE_ENABLED
SELECTTRACE(1,pParse,p,("end processing\n"));
#endif
+ explainSetInteger(pParse->iSelectId, iRestoreSelectId);
return rc;
}