1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-11 01:42:22 +03:00

Experimental optimization for distinct aggregates (e.g. "SELECT count(DISTINCT <expr) FROM ...").

FossilOrigin-Name: eb919611fd2f255e4ad1fe7db633363793169f6cf99c650eaefa48c022eb5d22
This commit is contained in:
dan
2021-03-09 16:06:25 +00:00
parent 52a0753152
commit 4fcb30b7d7
5 changed files with 115 additions and 74 deletions

View File

@@ -2598,6 +2598,7 @@ struct AggInfo {
FuncDef *pFunc; /* The aggregate function implementation */
int iMem; /* Memory location that acts as accumulator */
int iDistinct; /* Ephemeral table used to enforce DISTINCT */
int iDistAddr; /* Addres of OP_OpenEphemeral */
} *aFunc;
int nFunc; /* Number of entries in aFunc[] */
u32 selId; /* Select to which this AggInfo belongs */