/ Check-in [24924a58]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix an unreachable conditional in the WHERE clause analysis logic.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 24924a58197e558a9e8800cc5c91dc8fb32f3557
User & Date: drh 2015-09-05 19:21:00
Context
2015-09-05
22:36
Omit all use of Expr nodes for TK_AS, as those nodes no longer served a useful purpose and in fact interferred with the query planner. check-in: 7ab0b258 user: drh tags: trunk
19:52
Experiment with a different fts5 leaf page format that allows faster seeks. check-in: a1f4c3b5 user: dan tags: fts5-incompatible
19:21
Fix an unreachable conditional in the WHERE clause analysis logic. check-in: 24924a58 user: drh tags: trunk
19:07
Get STAT4 range scan estimates work again when the bounds are determined by date/time functions. check-in: d2761357 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/where.c.

   187    187            && pTerm->u.leftColumn==iColumn
   188    188            && (iColumn!=(-2)
   189    189                  || sqlite3ExprCompare(pTerm->pExpr->pLeft,pScan->pIdxExpr,iCur)==0)
   190    190            && (pScan->iEquiv<=1 || !ExprHasProperty(pTerm->pExpr, EP_FromJoin))
   191    191           ){
   192    192             if( (pTerm->eOperator & WO_EQUIV)!=0
   193    193              && pScan->nEquiv<ArraySize(pScan->aiCur)
   194         -           && (pX = sqlite3ExprSkipCollate(pTerm->pExpr->pRight))->op==TK_COLUMN
   195    194             ){
   196    195               int j;
          196  +            pX = sqlite3ExprSkipCollate(pTerm->pExpr->pRight);
          197  +            assert( pX->op==TK_COLUMN );
   197    198               for(j=0; j<pScan->nEquiv; j++){
   198    199                 if( pScan->aiCur[j]==pX->iTable
   199    200                  && pScan->aiColumn[j]==pX->iColumn ){
   200    201                     break;
   201    202                 }
   202    203               }
   203    204               if( j==pScan->nEquiv ){