mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-14 00:22:38 +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:
@@ -3605,7 +3605,12 @@ expr_code_doover:
|
||||
** constant.
|
||||
*/
|
||||
int iReg = sqlite3ExprCodeTarget(pParse, pExpr->pLeft,target);
|
||||
int aff = sqlite3TableColumnAffinity(pExpr->y.pTab, pExpr->iColumn);
|
||||
int aff;
|
||||
if( pExpr->y.pTab ){
|
||||
aff = sqlite3TableColumnAffinity(pExpr->y.pTab, pExpr->iColumn);
|
||||
}else{
|
||||
aff = pExpr->affExpr;
|
||||
}
|
||||
if( aff>SQLITE_AFF_BLOB ){
|
||||
static const char zAff[] = "B\000C\000D\000E";
|
||||
assert( SQLITE_AFF_BLOB=='A' );
|
||||
|
||||
Reference in New Issue
Block a user