]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fix a bug [3557ad65a07] that causes incorrect DISTINCT processing on
authordrh <drh@noemail.net>
Sat, 3 Mar 2012 00:34:47 +0000 (00:34 +0000)
committerdrh <drh@noemail.net>
Sat, 3 Mar 2012 00:34:47 +0000 (00:34 +0000)
an indexed query involving the IN operator.

FossilOrigin-Name: dec9a995d7012a1f85be4edb71240b9d4f07c60e

manifest
manifest.uuid
src/where.c

index 6fa62fc1773250bc4b6c4d4bb8ed9565effc6a9d..3e364d2766847c912147c3f7d385eb4d48123e92 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Fix\stest\spragma-19.5\sso\sthat\sit\sworks\son\sfile\snames\sthat\smay\scontain\sspaces\sand/or\sbackslashes.
-D 2012-03-02T22:41:06.784
+C Fix\sa\sbug\s[3557ad65a07]\sthat\scauses\sincorrect\sDISTINCT\sprocessing\son\nan\sindexed\squery\sinvolving\sthe\sIN\soperator.
+D 2012-03-03T00:34:47.462
 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
 F Makefile.in 3f79a373e57c3b92dabf76f40b065e719d31ac34
 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@@ -253,7 +253,7 @@ F src/vtab.c ab90fb600a3f5e4b7c48d22a4cdb2d6b23239847
 F src/wal.c 7bb3ad807afc7973406c805d5157ec7a2f65e146
 F src/wal.h 29c197540b19044e6cd73487017e5e47a1d3dac6
 F src/walker.c 3112bb3afe1d85dc52317cb1d752055e9a781f8f
-F src/where.c af623942514571895818b9b7ae11db95ae3b3d88
+F src/where.c f2cf59751f7facb4c422adf83ddc989aa5772874
 F test/8_3_names.test 631ea964a3edb091cf73c3b540f6bcfdb36ce823
 F test/aggerror.test a867e273ef9e3d7919f03ef4f0e8c0d2767944f2
 F test/alias.test 4529fbc152f190268a15f9384a5651bbbabc9d87
@@ -991,7 +991,7 @@ F tool/tostr.awk e75472c2f98dd76e06b8c9c1367f4ab07e122d06
 F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
 F tool/warnings-clang.sh 9f406d66e750e8ac031c63a9ef3248aaa347ef2a
 F tool/warnings.sh fbc018d67fd7395f440c28f33ef0f94420226381
-P 74d224b14467d8a6915d3cf372f45e0d28708fa2
-R 1b3b0133ab927bace43b063fe5fb3563
-U mistachkin
-Z 8931ed203e5c3d9dfd3529ebd0c654df
+P 9aaa1ab7c63c9045fecf5e965b333cc5f28b0791
+R 0fde9a1f5b219b6e9128e202fe652a01
+U drh
+Z 8bae0564fba3f81fa4a316b685f23026
index e9e40ff7c13a29fdc26b8e941b189a11a11453c8..41df7bd95df29a0d34f05a5b3fbbf52b9e322042 100644 (file)
@@ -1 +1 @@
-9aaa1ab7c63c9045fecf5e965b333cc5f28b0791
\ No newline at end of file
+dec9a995d7012a1f85be4edb71240b9d4f07c60e
\ No newline at end of file
index 78efbf9790248f17da7b23da1b80be6f051b9c53..eda8d5fb8e89025cdd57d15e7ba5a2bba1416263 100644 (file)
@@ -3103,7 +3103,9 @@ static void bestBtreeIndex(
     /* If there is a DISTINCT qualifier and this index will scan rows in
     ** order of the DISTINCT expressions, clear bDist and set the appropriate
     ** flags in wsFlags. */
-    if( isDistinctIndex(pParse, pWC, pProbe, iCur, pDistinct, nEq) ){
+    if( isDistinctIndex(pParse, pWC, pProbe, iCur, pDistinct, nEq)
+     && (wsFlags & WHERE_COLUMN_IN)==0
+    ){
       bDist = 0;
       wsFlags |= WHERE_ROWID_RANGE|WHERE_COLUMN_RANGE|WHERE_DISTINCT;
     }