aboutsummaryrefslogtreecommitdiff
path: root/src/select.c
diff options
context:
space:
mode:
authordrh <>2025-07-03 00:17:27 +0000
committerdrh <>2025-07-03 00:17:27 +0000
commitdebc8f7bb7b62fb865251e140510d853b138b88b (patch)
tree2097fe599de536915979fd49bc06208ae90c74e2 /src/select.c
parentaa54d7a0ca03a4df516f25e66ff3c4801be07a7b (diff)
downloadsqlite-debc8f7bb7b62fb865251e140510d853b138b88b.tar.gz
sqlite-debc8f7bb7b62fb865251e140510d853b138b88b.zip
Minor tweaks to the exists-to-join optimization.
FossilOrigin-Name: 9cb600ad576c68647ed943a0773019312c5f01c9c1ca9ff0bf1214b03a531b48
Diffstat (limited to 'src/select.c')
-rw-r--r--src/select.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/select.c b/src/select.c
index fd99dc91f..9c79f6c67 100644
--- a/src/select.c
+++ b/src/select.c
@@ -7437,7 +7437,7 @@ static SQLITE_NOINLINE void existsToJoin(
else if( pWhere->op==TK_EXISTS ){
Select *pSub = pWhere->x.pSelect;
if( pSub->pSrc->nSrc==1
- && (pSub->selFlags & (SF_Aggregate|SF_Correlated))==SF_Correlated
+ && (pSub->selFlags & SF_Aggregate)==0
&& pSub->pWhere
){
memset(pWhere, 0, sizeof(*pWhere));