mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-18 10:21:03 +03:00
The interior of the RIGHT JOIN loop is now a subroutine.
FossilOrigin-Name: 549f5a7ee639de80f049445002f58e93c805f9a3d3db1987ec9d139ccef4805e
This commit is contained in:
@@ -33,6 +33,7 @@ typedef struct WhereScan WhereScan;
|
||||
typedef struct WhereOrCost WhereOrCost;
|
||||
typedef struct WhereOrSet WhereOrSet;
|
||||
typedef struct WhereMemBlock WhereMemBlock;
|
||||
typedef struct WhereRightJoin WhereRightJoin;
|
||||
|
||||
/*
|
||||
** This object is a header on a block of allocated memory that will be
|
||||
@@ -43,6 +44,16 @@ struct WhereMemBlock {
|
||||
u8 sz; /* Bytes of space */
|
||||
};
|
||||
|
||||
/*
|
||||
** Extra information attached to a WhereLevel that is a RIGHT JOIN.
|
||||
*/
|
||||
struct WhereRightJoin {
|
||||
int iMatch; /* Cursor used to determine prior matched rows */
|
||||
int regBloom; /* Bloom filter for iRJMatch */
|
||||
int regReturn; /* Return register for the interior subroutine */
|
||||
int addrSubrtn; /* Starting address for the interior subroutine */
|
||||
};
|
||||
|
||||
/*
|
||||
** This object contains information needed to implement a single nested
|
||||
** loop in WHERE clause.
|
||||
@@ -75,7 +86,7 @@ struct WhereLevel {
|
||||
int addrLikeRep; /* LIKE range processing address */
|
||||
#endif
|
||||
int regFilter; /* Bloom filter */
|
||||
int iRJMatch; /* Cursor or rowset used for matched RIGHT JOIN rows */
|
||||
WhereRightJoin *pRJ; /* Extra information for RIGHT JOIN */
|
||||
u8 iFrom; /* Which entry in the FROM clause */
|
||||
u8 op, p3, p5; /* Opcode, P3 & P5 of the opcode that ends the loop */
|
||||
int p1, p2; /* Operands of the opcode used to end the loop */
|
||||
|
||||
Reference in New Issue
Block a user