mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Consider the values bound to SQL variables when determining whether or not a
partial index may be used. FossilOrigin-Name: 7b59c353b805c64689b4ae9df347705acbb5f116346ad77af8ce087da7893747
This commit is contained in:
@@ -5005,7 +5005,9 @@ static struct SrcList_item *isSelfJoinView(
|
||||
if( pItem->zName==0 ) continue;
|
||||
if( sqlite3_stricmp(pItem->zDatabase, pThis->zDatabase)!=0 ) continue;
|
||||
if( sqlite3_stricmp(pItem->zName, pThis->zName)!=0 ) continue;
|
||||
if( sqlite3ExprCompare(pThis->pSelect->pWhere, pItem->pSelect->pWhere, -1) ){
|
||||
if( sqlite3ExprCompare(0,
|
||||
pThis->pSelect->pWhere, pItem->pSelect->pWhere, -1)
|
||||
){
|
||||
/* The view was modified by some other optimization such as
|
||||
** pushDownWhereTerms() */
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user