mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-18 10:21:03 +03:00
Fix a problem that comes up when using generated columns that evaluate to a
constant in an index and then making use of that index in a join. FossilOrigin-Name: 8b12e95fec7ce6e0de82a04ca3dfcf1a8e62e233b7382aa28a8a9be6e862b1af
This commit is contained in:
@@ -1141,6 +1141,8 @@ static int whereIndexExprTransColumn(Walker *p, Expr *pExpr){
|
||||
if( pExpr->op==TK_COLUMN ){
|
||||
IdxExprTrans *pX = p->u.pIdxTrans;
|
||||
if( pExpr->iTable==pX->iTabCur && pExpr->iColumn==pX->iTabCol ){
|
||||
assert( pExpr->y.pTab!=0 );
|
||||
pExpr->affExpr = sqlite3TableColumnAffinity(pExpr->y.pTab,pExpr->iColumn);
|
||||
pExpr->iTable = pX->iIdxCur;
|
||||
pExpr->iColumn = pX->iIdxCol;
|
||||
pExpr->y.pTab = 0;
|
||||
|
||||
Reference in New Issue
Block a user