1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-16 23:02:26 +03:00

Bring sqlite3_vtab_distinct() up to spec so that it works as described in the

documentation.

FossilOrigin-Name: 4289edf3c5e32a05b51f232020099b33f6f5e79b0ceca2b96baf1186168d9af6
This commit is contained in:
drh
2022-01-22 20:45:57 +00:00
parent 9b9fc74f2e
commit 68dc8151e0
4 changed files with 17 additions and 12 deletions

View File

@@ -1206,8 +1206,8 @@ static sqlite3_index_info *allocateIndexInfo(
}
if( i==n){
nOrderBy = n;
if( (pWInfo->wctrlFlags & WHERE_DISTINCTBY) ){
eDistinct = 1;
if( (pWInfo->wctrlFlags & (WHERE_GROUPBY|WHERE_DISTINCTBY)) ){
eDistinct = 1 + ((pWInfo->wctrlFlags & WHERE_DISTINCTBY)!=0);
}
}
}