1
0
mirror of https://github.com/sqlite/sqlite.git synced 2026-10-30 01:43:10 +03:00

Fix a problem in the query flattener associated with RIGHT JOIN, as

reported by [bugs:/info/2026-10-11T16:49:00Z|Bug 2026-10-11T16:49:00Z].
This problem surfaced after the fix to
[forum:/info/2025-08-21T14:14:03Z|Forum post 2025-08-21T14:14:03Z]
at check-in [e0beda7ffe92abf6].  Before that, the query would not parse.

FossilOrigin-Name: e6e27e37eb8c3159d67529959694971f35a589da75648e207c44e317e6d160be
This commit is contained in:
drh
2026-10-11 17:44:08 +00:00
parent d85a80711c
commit 513c19fa38
4 changed files with 25 additions and 11 deletions

View File

@@ -4124,7 +4124,9 @@ static int renumberCursorsCb(Walker *pWalker, Expr *pExpr){
if( op==TK_COLUMN || op==TK_IF_NULL_ROW ){
renumberCursorDoMapping(pWalker, &pExpr->iTable);
}
if( ExprHasProperty(pExpr, EP_OuterON) ){
if( ExprHasProperty(pExpr, (EP_OuterON|EP_InnerON)) ){
testcase( ExprHasProperty(pExpr, EP_OuterON) );
testcase( ExprHasProperty(pExpr, EP_InnerON) );
renumberCursorDoMapping(pWalker, &pExpr->w.iJoin);
}
return WRC_Continue;