1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-18 10:21:03 +03:00

Ensure that the NULL-scan pass counter is initialized when a ORDER BY NULLS LAST

is used on the right table of a LEFT JOIN.  Ticket [e12a0ae526bb51c7].

FossilOrigin-Name: 704bb9a39acbee420c1d6ac9eb1466a02dd77d3334b938bfddf235973129b5fe
This commit is contained in:
drh
2020-03-02 01:16:33 +00:00
parent 0a21ea997d
commit 7f05d52c4c
4 changed files with 54 additions and 9 deletions

View File

@@ -1711,6 +1711,9 @@ Bitmask sqlite3WhereCodeOneLoopStart(
nExtraReg = 1;
bSeekPastNull = 1;
pLevel->regBignull = regBignull = ++pParse->nMem;
if( pLevel->iLeftJoin ){
sqlite3VdbeAddOp2(v, OP_Integer, 0, regBignull);
}
pLevel->addrBignull = sqlite3VdbeMakeLabel(pParse);
}