aboutsummaryrefslogtreecommitdiff
path: root/src/wherecode.c
diff options
context:
space:
mode:
authordan <dan@noemail.net>2020-01-04 16:55:57 +0000
committerdan <dan@noemail.net>2020-01-04 16:55:57 +0000
commit74ebaadcdd8b1058bbc80bf61334fe09da1c64b5 (patch)
treea1ee43b8fd756ca0f38d6fa570a36ad7f8db83c7 /src/wherecode.c
parentf6ea97ea3d278c212ef366e255051e52ca352332 (diff)
downloadsqlite-74ebaadcdd8b1058bbc80bf61334fe09da1c64b5.tar.gz
sqlite-74ebaadcdd8b1058bbc80bf61334fe09da1c64b5.zip
Fix a problem where the loop for the RHS of a LEFT JOIN uses values from an IN() clause as the second or subsequent field of an index.
FossilOrigin-Name: 95ef68966c50f311830cba8c9257a4085c93011d205e0e31867c2917fa62a48e
Diffstat (limited to 'src/wherecode.c')
-rw-r--r--src/wherecode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wherecode.c b/src/wherecode.c
index beb23e0c1..03e393498 100644
--- a/src/wherecode.c
+++ b/src/wherecode.c
@@ -593,7 +593,7 @@ static int codeEqualityTerm(
if( i==iEq ){
pIn->iCur = iTab;
pIn->eEndLoopOp = bRev ? OP_Prev : OP_Next;
- if( iEq>0 && (pLoop->wsFlags & WHERE_VIRTUALTABLE)==0 ){
+ if( iEq>0 ){
pIn->iBase = iReg - i;
pIn->nPrefix = i;
pLoop->wsFlags |= WHERE_IN_EARLYOUT;