1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-30 19:03:16 +03:00

Handle equality and range constraints on the "term" column of fts5vocab tables. Also have the same module report columns using names instead of indexes.

FossilOrigin-Name: 6020d96ab47a0bebe41f691a3f44fd55d8b2d2b7
This commit is contained in:
dan
2015-10-17 19:49:01 +00:00
parent b0df963465
commit 05903e6a87
7 changed files with 299 additions and 65 deletions

View File

@ -2021,20 +2021,20 @@ static void fts5ApiCallback(
** Given cursor id iId, return a pointer to the corresponding Fts5Index
** object. Or NULL If the cursor id does not exist.
**
** If successful, set *pnCol to the number of indexed columns in the
** table before returning.
** If successful, set *ppConfig to point to the associated config object
** before returning.
*/
Fts5Index *sqlite3Fts5IndexFromCsrid(
Fts5Global *pGlobal,
i64 iCsrId,
int *pnCol
Fts5Global *pGlobal, /* FTS5 global context for db handle */
i64 iCsrId, /* Id of cursor to find */
Fts5Config **ppConfig /* OUT: Configuration object */
){
Fts5Cursor *pCsr;
Fts5Table *pTab;
pCsr = fts5CursorFromCsrid(pGlobal, iCsrId);
pTab = (Fts5Table*)pCsr->base.pVtab;
*pnCol = pTab->pConfig->nCol;
*ppConfig = pTab->pConfig;
return pTab->pIndex;
}