diff options
author | drh <drh@noemail.net> | 2020-01-16 16:12:07 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2020-01-16 16:12:07 +0000 |
commit | 39df24a3f02495e5ef6bb5ea8ce029a2c1e377e6 (patch) | |
tree | 27986af6c57abdcb67c76e7771b107eae83ca873 /src | |
parent | 7db212a70b6520832a22e98f5f506c6cc7826f3e (diff) | |
download | sqlite-39df24a3f02495e5ef6bb5ea8ce029a2c1e377e6.tar.gz sqlite-39df24a3f02495e5ef6bb5ea8ce029a2c1e377e6.zip |
Do not allow the constant-propagation optimization to apple to ON/USING clause
terms as it does not help and it might cause downstream problems.
FossilOrigin-Name: 1bc783da63d58b05c690468b569cb2787846357b63c1100d11777666c5787bf4
Diffstat (limited to 'src')
-rw-r--r-- | src/select.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/select.c b/src/select.c index 8df63dfff..723ca9cb1 100644 --- a/src/select.c +++ b/src/select.c @@ -4233,7 +4233,7 @@ static int propagateConstantExprRewrite(Walker *pWalker, Expr *pExpr){ int i; WhereConst *pConst; if( pExpr->op!=TK_COLUMN ) return WRC_Continue; - if( ExprHasProperty(pExpr, EP_FixedCol) ) return WRC_Continue; + if( ExprHasProperty(pExpr, EP_FixedCol|EP_FromJoin) ) return WRC_Continue; pConst = pWalker->u.pConst; for(i=0; i<pConst->nConst; i++){ Expr *pColumn = pConst->apExpr[i*2]; |