Extra robustness in the code that causes cursors to return NULL when they

are participating in an OUTER JOIN.

FossilOrigin-Name: 672c2869ef48e08447d37b0d76a1850cdafbe30ca1906ec98c55e3ab496fd9a6
This commit is contained in:
drh
2024-04-22 13:31:24 +00:00
parent 2469350ad9
commit 4f2f6c74ca
4 changed files with 15 additions and 18 deletions
+5 -7
View File
@@ -2739,13 +2739,11 @@ SQLITE_NOINLINE void sqlite3WhereRightJoinLoop(
v, OP_Null, 0, pRight->regResult,
pRight->regResult + pRight->pSelect->pEList->nExpr-1
);
sqlite3VdbeAddOp1(v, OP_OpenPseudo, pWInfo->a[k].iTabCur);
}else{
sqlite3VdbeAddOp1(v, OP_NullRow, pWInfo->a[k].iTabCur);
iIdxCur = pWInfo->a[k].iIdxCur;
if( iIdxCur ){
sqlite3VdbeAddOp1(v, OP_NullRow, iIdxCur);
}
}
sqlite3VdbeAddOp1(v, OP_NullRow, pWInfo->a[k].iTabCur);
iIdxCur = pWInfo->a[k].iIdxCur;
if( iIdxCur ){
sqlite3VdbeAddOp1(v, OP_NullRow, iIdxCur);
}
}
if( (pTabItem->fg.jointype & JT_LTORJ)==0 ){