From: drh Date: Tue, 17 Jun 2014 02:46:55 +0000 (+0000) Subject: Do not attempt to create an automatic index on a constant constraint, as X-Git-Tag: version-3.8.6~110^2~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9978e6a680fb24a29ac25854e6948b9d8ab50c21;p=thirdparty%2Fsqlite.git Do not attempt to create an automatic index on a constant constraint, as doing so is pointless. FossilOrigin-Name: d6883e960f61365729f279a3c1f2c050beb49a55 --- diff --git a/manifest b/manifest index 33d3388ac9..420bfeac91 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Fix\sCSV\simport\sissue,\sreported\svia\sthe\smailing\slist,\sin\sthe\sshell\swhen\sthe\sfile\sto\sbe\simported\sends\swith\san\sempty\sline. -D 2014-06-16T22:45:28.779 +C Do\snot\sattempt\sto\screate\san\sautomatic\sindex\son\sa\sconstant\sconstraint,\sas\ndoing\sso\sis\spointless. +D 2014-06-17T02:46:55.317 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f F Makefile.in ed5e4aae4799f724699d5509fac2977786414dbb F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23 @@ -296,7 +296,7 @@ F src/vtab.c 21b932841e51ebd7d075e2d0ad1415dce8d2d5fd F src/wal.c 264df50a1b33124130b23180ded2e2c5663c652a F src/wal.h df01efe09c5cb8c8e391ff1715cca294f89668a4 F src/walker.c 11edb74d587bc87b33ca96a5173e3ec1b8389e45 -F src/where.c 5ee08882fdc1a4661766a6dae639bd79cabb28fa +F src/where.c 46e94a513fa783a950889e924b253339e498d600 F src/whereInt.h 929c1349b5355fd44f22cee5c14d72b3329c58a6 F test/8_3_names.test ebbb5cd36741350040fd28b432ceadf495be25b2 F test/aggerror.test a867e273ef9e3d7919f03ef4f0e8c0d2767944f2 @@ -1177,7 +1177,10 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4 F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32 F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f -P 3181d2069a788adc719decf65dc1bd2e16650c87 -R e15c594b7f416cdaa03cc5ded52dfa16 -U mistachkin -Z ca873ea75a4dc77a2f68671379d28791 +P fc918f7d332b8f7cabc79a0f1586bd6760d14d40 +R c05b0f400c5eb501cd2d5ddbdc6430c7 +T *branch * autoindex-improvements +T *sym-autoindex-improvements * +T -sym-trunk * +U drh +Z 93418c6f90150cfc0b0ae16a3328fb2a diff --git a/manifest.uuid b/manifest.uuid index 2f140ef165..7f4c5b13a3 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -fc918f7d332b8f7cabc79a0f1586bd6760d14d40 \ No newline at end of file +d6883e960f61365729f279a3c1f2c050beb49a55 \ No newline at end of file diff --git a/src/where.c b/src/where.c index 8c6f4bbbe3..d2723dd5b6 100644 --- a/src/where.c +++ b/src/where.c @@ -4529,6 +4529,7 @@ static int whereLoopAddBtree( WhereTerm *pWCEnd = pWC->a + pWC->nTerm; for(pTerm=pWC->a; rc==SQLITE_OK && pTermprereqRight & pNew->maskSelf ) continue; + if( pTerm->prereqRight==0 ) continue; if( termCanDriveIndex(pTerm, pSrc, 0) ){ pNew->u.btree.nEq = 1; pNew->u.btree.nSkip = 0;