Lines Matching refs:pList
10861 ** for(rc=sqlite3_vtab_in_first(pList, &pVal);
10863 ** rc=sqlite3_vtab_in_next(pList, &pVal)
20011 ** Expr.x.pList is a list of arguments if the expression is an SQL function,
20015 ** Expr.flags mask, then Expr.x.pSelect is valid. Otherwise, Expr.x.pList is
20052 ** the subtrees in Expr.x.pList or Expr.x.pSelect are always separately
20079 ExprList *pList; /* op = IN, EXISTS, SELECT, CASE, FUNCTION, BETWEEN */
20137 #define EP_xIsSelect 0x001000 /* x.pSelect is valid (otherwise x.pList is) */
34690 pFarg = pExpr->x.pList;
34723 sqlite3TreeViewExprList(pView, pOB->x.pList, pWin!=0, "ORDERBY");
34734 sqlite3TreeViewExprList(pView, pExpr->x.pList, 0, "ORDERBY");
34766 sqlite3TreeViewExprList(pView, pExpr->x.pList, 0, 0);
34780 ** Y is stored in pExpr->pList->a[0].pExpr.
34781 ** Z is stored in pExpr->pList->a[1].pExpr.
34787 assert( pExpr->x.pList->nExpr==2 );
34788 pY = pExpr->x.pList->a[0].pExpr;
34789 pZ = pExpr->x.pList->a[1].pExpr;
34812 sqlite3TreeViewExprList(pView, pExpr->x.pList, 0, 0);
34839 sqlite3TreeViewBareExprList(pView, pExpr->x.pList, z);
34895 const ExprList *pList,
34899 if( pList==0 ){
34904 for(i=0; i<pList->nExpr; i++){
34905 int j = pList->a[i].u.x.iOrderByCol;
34906 u8 sortFlags = pList->a[i].fg.sortFlags;
34907 char *zName = pList->a[i].zEName;
34908 int moreToFollow = i<pList->nExpr - 1;
34914 switch( pList->a[i].fg.eEName ){
34920 if( pList->a[i].fg.bUsed ) fprintf(stdout, "(used) ");
34921 if( pList->a[i].fg.bUsingTerm ) fprintf(stdout, "(USING-term) ");
34922 if( pList->a[i].fg.bNoExpand ) fprintf(stdout, "(NoExpand) ");
34940 sqlite3TreeViewExpr(pView, pList->a[i].pExpr, moreToFollow);
34949 const ExprList *pList,
34954 sqlite3TreeViewBareExprList(pView, pList, zLabel);
34963 const IdList *pList,
34967 if( pList==0 ){
34972 for(i=0; i<pList->nId; i++){
34973 char *zName = pList->a[i].zName;
34974 int moreToFollow = i<pList->nId - 1;
34985 const IdList *pList,
34990 sqlite3TreeViewBareIdList(pView, pList, zLabel);
59291 static struct RowSetEntry *rowSetListToTree(struct RowSetEntry *pList){
59296 assert( pList!=0 );
59297 p = pList;
59298 pList = p->pRight;
59300 for(iDepth=1; pList; iDepth++){
59302 p = pList;
59303 pList = p->pRight;
59305 p->pRight = rowSetNDeepTree(&pList, iDepth);
62733 PgHdr *pList; /* List of dirty pages to revert */
62744 pList = sqlite3PcacheDirtyList(pPager->pPCache);
62745 while( pList && rc==SQLITE_OK ){
62746 PgHdr *pNext = pList->pDirty;
62747 rc = pagerUndoCallback((void *)pPager, pList->pgno);
62748 pList = pNext;
62756 ** the contents of the list of pages headed by pList (connected by pDirty),
62765 PgHdr *pList, /* List of frames to log */
62770 int nList; /* Number of pages in pList */
62774 assert( pList );
62777 for(p=pList; p && p->pDirty; p=p->pDirty){
62782 assert( pList->pDirty==0 || isCommit );
62788 PgHdr **ppNext = &pList;
62790 for(p=pList; (*ppNext = p)!=0; p=p->pDirty){
62796 assert( pList );
62802 if( pList->pgno==1 ) pager_write_changecounter(pList);
62804 pPager->pageSize, pList, nTruncate, isCommit, pPager->walSyncFlags
62807 for(p=pList; p; p=p->pDirty){
62813 pList = sqlite3PcacheDirtyList(pPager->pPCache);
62814 for(p=pList; p; p=p->pDirty){
64013 static int pager_write_pagelist(Pager *pPager, PgHdr *pList){
64020 assert( isOpen(pPager->fd) || pList->pDirty==0 );
64037 && (pList->pDirty || pList->pgno>pPager->dbHintSize)
64044 while( rc==SQLITE_OK && pList ){
64045 Pgno pgno = pList->pgno;
64055 if( pgno<=pPager->dbSize && 0==(pList->flags&PGHDR_DONT_WRITE) ){
64059 assert( (pList->flags&PGHDR_NEED_SYNC)==0 );
64060 if( pList->pgno==1 ) pager_write_changecounter(pList);
64062 pData = pList->pData;
64080 sqlite3BackupUpdate(pPager->pBackup, pgno, (u8*)pList->pData);
64083 PAGERID(pPager), pgno, pager_pagehash(pList)));
64089 pager_set_pagehash(pList);
64090 pList = pList->pDirty;
64273 PgHdr *pList = sqlite3PcacheDirtyList(pPager->pPCache);
64275 while( rc==SQLITE_OK && pList ){
64276 PgHdr *pNext = pList->pDirty;
64277 if( pList->nRef==0 ){
64278 rc = pagerStress((void*)pPager, pList);
64280 pList = pNext;
66083 PgHdr *pList;
66086 pList = sqlite3PcacheDirtyList(pPager->pPCache);
66087 if( pList==0 ){
66091 pList = pPageOne;
66092 pList->pDirty = 0;
66095 if( ALWAYS(pList) ){
66096 rc = pagerWalFrames(pPager, pList, pPager->dbSize, 1);
66199 pList = sqlite3PcacheDirtyList(pPager->pPCache);
66204 rc = pager_write_pagelist(pPager, pList);
66234 rc = pager_write_pagelist(pPager, pList);
71456 PgHdr *pList, /* List of dirty pages to write */
71463 PgHdr *p; /* Iterator to run through pList with. */
71472 assert( pList );
71480 { int cnt; for(cnt=0, p=pList; p; p=p->pDirty, cnt++){}
71555 for(p=pList; p; p=p->pDirty){
71650 for(p=pList; p && rc==SQLITE_OK; p=p->pDirty){
71693 PgHdr *pList, /* List of dirty pages to write */
71700 rc = walFrames(pWal, szPage, pList, nTruncate, isCommit, sync_flags);
75951 BtShared *pList;
75962 pList = GLOBAL(BtShared*,sqlite3SharedCacheList);
75963 while( ALWAYS(pList) && pList->pNext!=pBt ){
75964 pList=pList->pNext;
75966 if( ALWAYS(pList) ){
75967 pList->pNext = pBt->pNext;
87169 ExprList *pList = 0; /* Function arguments */
87175 pList = p->x.pList;
87176 if( pList ) nVal = pList->nExpr;
87189 if( pList ){
87196 rc = sqlite3Stat4ValueFromExpr(pCtx->pParse, pList->a[i].pExpr, aff,
106555 SorterRecord *pList; /* Linked list of records */
106556 u8 *aMemory; /* If non-NULL, bulk memory to hold pList */
106557 i64 szPMA; /* Size of pList as PMA in bytes */
107442 vdbeSorterRecordFree(0, pTask->list.pList);
107634 vdbeSorterRecordFree(0, pSorter->list.pList);
107636 pSorter->list.pList = 0;
107788 ** Sort the linked list of records headed at pTask->pList. Return
107792 static int vdbeSorterSort(SortSubtask *pTask, SorterList *pList){
107801 p = pList->pList;
107807 if( pList->aMemory ){
107808 if( (u8*)p==pList->aMemory ){
107811 assert( p->u.iNext<sqlite3MallocSize(pList->aMemory) );
107812 pNext = (SorterRecord*)&pList->aMemory[p->u.iNext];
107836 pList->pList = p;
107933 ** Write the current contents of in-memory linked-list pList to a level-0
107946 static int vdbeSorterListToPMA(SortSubtask *pTask, SorterList *pList){
107954 i64 iSz = pList->szPMA + sqlite3VarintLen(pList->szPMA) + pTask->file.iEof;
107959 assert( pList->szPMA>0 );
107971 vdbeSorterExtendFile(db, pTask->file.pFd, pTask->file.iEof+pList->szPMA+9);
107976 rc = vdbeSorterSort(pTask, pList);
107986 vdbePmaWriteVarint(&writer, pList->szPMA);
107987 for(p=pList->pList; p; p=pNext){
107991 if( pList->aMemory==0 ) sqlite3_free(p);
107993 pList->pList = p;
107998 assert( rc!=SQLITE_OK || pList->pList==0 );
108137 assert( pTask->list.pList==0 );
108144 pSorter->list.pList = 0;
108221 assert( rc!=SQLITE_OK || pSorter->list.pList==0 );
108237 if( pSorter->list.pList ){
108238 iListOff = (u8*)pSorter->list.pList - pSorter->list.aMemory;
108246 pSorter->list.pList = (SorterRecord*)&aNew[iListOff];
108254 if( pSorter->list.pList ){
108255 pNew->u.iNext = (int)((u8*)(pSorter->list.pList) - pSorter->list.aMemory);
108262 pNew->u.pNext = pSorter->list.pList;
108267 pSorter->list.pList = pNew;
108992 if( pSorter->list.pList ){
109005 assert( pSorter->list.pList );
109057 SorterRecord *pFree = pSorter->list.pList;
109058 pSorter->list.pList = pFree->u.pNext;
109061 rc = pSorter->list.pList ? SQLITE_OK : SQLITE_DONE;
109088 *pnKey = pSorter->list.pList->nVal;
109089 pKey = SRVAL(pSorter->list.pList);
110084 static int walkWindowList(Walker *pWalker, Window *pList, int bOneOnly){
110086 for(pWin=pList; pWin; pWin=pWin->pNextWin){
110131 assert( pExpr->x.pList==0 || pExpr->pRight==0 );
110143 if( pExpr->x.pList ){
110144 if( sqlite3WalkExprList(pWalker, pExpr->x.pList) ) return WRC_Abort;
110994 assert( ExprUseXList(pExpr)==0 || pExpr->x.pList==0 );
111099 pExpr->x.pList = pFJMatch;
111436 ExprList *pList; /* The argument list */
111450 pList = pExpr->x.pList;
111451 n = pList ? pList->nExpr : 0;
111466 pExpr->iTable = exprProbability(pList->a[1].pExpr);
111514 ExprSetProperty(pList->a[ii].pExpr, EP_SubtArg);
111629 sqlite3WalkExprList(pWalker, pList);
111634 sqlite3WalkExprList(pWalker, pExpr->pLeft->x.pList);
111755 nRight = sqlite3ExprVectorSize(pExpr->x.pList->a[0].pExpr);
111757 nRight = sqlite3ExprVectorSize(pExpr->x.pList->a[1].pExpr);
112516 ExprList *pList /* The expression list to be analyzed. */
112521 if( pList==0 ) return SQLITE_OK;
112529 for(i=0; i<pList->nExpr; i++){
112530 Expr *pExpr = pList->a[i].pExpr;
112609 ExprList *pList /* Expression list to resolve. May be NULL. */
112640 if( pList ) rc = sqlite3ResolveExprListNames(&sNC, pList);
112725 return sqlite3ExprAffinity(pExpr->x.pList->a[0].pExpr);
112793 ExprList *pList = pExpr->x.pList;
112794 assert( ExprUseXList(pExpr) && pList!=0 );
112795 assert( pList->nExpr > 0);
112796 for(ii=1; ii<pList->nExpr; ii+=2){
112797 res |= sqlite3ExprDataType(pList->a[ii].pExpr);
112799 if( pList->nExpr % 2 ){
112800 res |= sqlite3ExprDataType(pList->a[pList->nExpr-1].pExpr);
112867 assert( pExpr->x.pList->nExpr>0 );
112869 pExpr = pExpr->x.pList->a[0].pExpr;
112920 p = p->x.pList->a[0].pExpr;
112934 assert( !ExprUseXList(p) || p->x.pList==0 || p->pRight==0 );
112935 if( ExprUseXList(p) && p->x.pList!=0 && !db->mallocFailed ){
112937 for(i=0; i<p->x.pList->nExpr; i++){
112938 if( ExprHasProperty(p->x.pList->a[i].pExpr, EP_Collate) ){
112939 pNext = p->x.pList->a[i].pExpr;
113159 return pExpr->x.pList->nExpr;
113192 return pVector->x.pList->a[i].pExpr;
113255 ppVector = &pVector->x.pList->a[iField].pExpr;
113325 *ppExpr = pVector->x.pList->a[iField].pExpr;
113487 ** argument. An expression with no children, Expr.pList or
113492 ** Also propagate EP_Propagate flags up from Expr.x.pList to Expr.flags,
113502 }else if( p->x.pList ){
113503 heightOfExprList(p->x.pList, &nHeight);
113504 p->flags |= EP_Propagate & sqlite3ExprListFlags(p->x.pList);
113514 ** Also propagate all EP_Propagate flags from the Expr.x.pList into
113534 ** Propagate all EP_Propagate flags from the Expr.x.pList into
113539 if( p && ExprUseXList(p) && p->x.pList ){
113540 p->flags |= EP_Propagate & sqlite3ExprListFlags(p->x.pList);
113753 nExprElem = pExpr->x.pList->nExpr;
113764 pSel = sqlite3SelectNew(pParse, pExpr->x.pList, 0, 0, 0, 0, 0, SF_Values,0);
113765 pExpr->x.pList = 0;
113816 ExprList *pList, /* Argument list */
113825 sqlite3ExprListDelete(db, pList); /* Avoid memory leak when malloc fails */
113830 if( pList
113831 && pList->nExpr > pParse->db->aLimit[SQLITE_LIMIT_FUNCTION_ARG]
113836 pNew->x.pList = pList;
113883 if( pExpr->x.pList==0 || NEVER(pExpr->x.pList->nExpr==0) ){
113904 pOB->x.pList = pOrderBy;
114045 assert( !ExprUseXList(p) || p->x.pList==0 );
114050 assert( (ExprUseXList(p) && p->x.pList==0) || p->pRight==0 );
114058 sqlite3ExprListDelete(db, p->x.pList);
114185 if( p->pLeft || p->x.pList ){
114217 ** substructure such as Expr.x.pList, Expr.x.pSelect, and Expr.y.pWin.
114348 /* Fill in the pNew->x.pSelect or pNew->x.pList member. */
114352 pNew->x.pList = sqlite3ExprListDup(db, p->x.pList,
114658 ** Add a new element to the end of an expression list. If pList is
114661 ** The pList argument must be either NULL or a pointer to an ExprList
114674 ExprList *pList;
114676 pList = sqlite3DbMallocRawNN(db, SZ_EXPRLIST(4));
114677 if( pList==0 ){
114681 pList
114682 pList->nExpr = 1;
114683 pItem = &pList->a[0];
114686 return pList;
114690 ExprList *pList, /* List to which to append. Might be NULL */
114695 pList->nAlloc *= 2;
114696 pNew = sqlite3DbRealloc(db, pList, SZ_EXPRLIST(pList->nAlloc));
114698 sqlite3ExprListDelete(db, pList);
114702 pList = pNew;
114704 pItem = &pList->a[pList->nExpr++];
114707 return pList;
114711 ExprList *pList, /* List to which to append. Might be NULL */
114715 if( pList==0 ){
114718 if( pList->nAlloc<pList->nExpr+1 ){
114719 return sqlite3ExprListAppendGrow(pParse->db,pList,pExpr);
114721 pItem = &pList->a[pList->nExpr++];
114724 return pList;
114735 ** expression list pList. In the case of a subquery on the RHS, append
114740 ExprList *pList, /* List to which to append. Might be NULL */
114747 int iFirst = pList ? pList->nExpr : 0;
114768 pList = sqlite3ExprListAppend(pParse, pList, pSubExpr);
114769 if( pList ){
114770 assert( pList->nExpr==iFirst+i+1 );
114771 pList->a[pList->nExpr-1].zEName = pColumns->a[i].zName;
114776 if( !db->mallocFailed && pExpr->op==TK_SELECT && ALWAYS(pList!=0) ){
114777 Expr *pFirst = pList->a[iFirst].pExpr;
114794 return pList;
114834 ** pList might be NULL following an OOM error. But pName should never be
114840 ExprList *pList, /* List to which to add the span. */
114844 assert( pList!=0 || pParse->db->mallocFailed!=0 );
114846 if( pList ){
114848 assert( pList->nExpr>0 );
114849 pItem = &pList->a[pList->nExpr-1];
114869 ** pList might be NULL following an OOM error. But pSpan should never be
114875 ExprList *pList, /* List to which to add the span. */
114880 assert( pList!=0 || db->mallocFailed!=0 );
114881 if( pList ){
114882 struct ExprList_item *pItem = &pList->a[pList->nExpr-1];
114883 assert( pList->nExpr>0 );
114911 static SQLITE_NOINLINE void exprListDeleteNN(sqlite3 *db, ExprList *pList){
114912 int i = pList->nExpr;
114913 struct ExprList_item *pItem = pList->a;
114914 assert( pList->nExpr>0 );
114921 sqlite3DbNNFreeNN(db, pList);
114923 SQLITE_PRIVATE void sqlite3ExprListDelete(sqlite3 *db, ExprList *pList){
114924 if( pList ) exprListDeleteNN(db, pList);
114926 SQLITE_PRIVATE void sqlite3ExprListDeleteGeneric(sqlite3 *db, void *pList){
114927 if( ALWAYS(pList) ) exprListDeleteNN(db, (ExprList*)pList);
114934 SQLITE_PRIVATE u32 sqlite3ExprListFlags(const ExprList *pList){
114937 assert( pList!=0 );
114938 for(i=0; i<pList->nExpr; i++){
114939 Expr *pExpr = pList->a[i].pExpr;
115132 ExprList *pList; /* List of arguments */
115138 || (pList = pExpr->x.pList)==0
115142 n = pList->nExpr;
115143 sqlite3WalkExprList(pWalker, pList);
116055 && (!sqlite3InRhsIsConstant(pParse,pX) || pX->x.pList->nExpr<=2)
116402 }else if( ALWAYS(pExpr->x.pList!=0) ){
116412 ExprList *pList = pExpr->x.pList;
116429 for(i=pList->nExpr, pItem=pList->a; i>0; i--, pItem++){
116755 ExprList *pList;
116763 pList = pExpr->x.pList;
116769 for(ii=0; ii<pList->nExpr; ii++){
116770 r2 = sqlite3ExprCodeTemp(pParse, pList->a[ii].pExpr, ®ToFree);
116771 if( regCkNull && sqlite3ExprCanBeNull(pList->a[ii].pExpr) ){
116775 if( ii<pList->nExpr-1 || destIfNull!=destIfFalse ){
116779 VdbeCoverageIf(v, ii<pList->nExpr-1 && op==OP_Eq);
116780 VdbeCoverageIf(v, ii==pList->nExpr-1 && op==OP_Eq);
116781 VdbeCoverageIf(v, ii<pList->nExpr-1 && op==OP_NotNull);
116782 VdbeCoverageIf(v, ii==pList->nExpr-1 && op==OP_NotNull);
117194 sqlite3ExprCodeFactorable(pParse, p->x.pList->a[i].pExpr, i+iResult);
117250 caseExpr.x.pList = pFarg;
117358 n = ALWAYS(pExpr->x.pList) ? pExpr->x.pList->nExpr : 0;
117997 pFarg = pExpr->x.pList;
118152 ** Y is stored in pExpr->pList->a[0].pExpr.
118153 ** Z is stored in pExpr->pList->a[1].pExpr.
118299 ** Y is in the last element of pExpr->x.pList if pExpr->x.pList->nExpr is
118300 ** odd. The Y is also optional. If the number of elements in x.pList
118302 ** Ei is in pExpr->pList->a[i*2] and Ri is pExpr->pList->a[i*2+1].
118321 assert( ExprUseXList(pExpr) && pExpr->x.pList!=0 );
118322 assert(pExpr->x.pList->nExpr > 0);
118323 pEList = pExpr->x.pList;
118583 ** usually be pList->nExpr but might be reduced if SQLITE_ECEL_OMITREF
118600 ExprList *pList, /* The expression list to be coded */
118609 assert( pList!=0 );
118612 n = pList->nExpr;
118614 for(pItem=pList->a, i=0; i<n; i++, pItem++){
118699 compLeft.pRight = pExpr->x.pList->a[0].pExpr;
118702 compRight.pRight = pExpr->x.pList->a[1].pExpr;
119260 if( sqlite3ExprListCompare(pA->x.pList, pB->x.pList, iTab) ) return 2;
119338 assert( ExprUseXSelect(p) || (p->x.pList!=0 && p->x.pList->nExpr>0) );
119342 ExprList *pList;
119344 pList = p->x.pList;
119345 assert( pList!=0 );
119346 assert( pList->nExpr==2 );
119348 if( exprImpliesNotNull(pParse, pList->a[0].pExpr, pNN, iTab, 1)
119349 || exprImpliesNotNull(pParse, pList->a[1].pExpr, pNN, iTab, 1)
119419 ExprList *pList;
119424 if( pExpr->x.pList==0 ) return 0;
119425 pDef = sqlite3FindFunction(db, z, pExpr->x.pList->nExpr, ENC(db), 0);
119438 pList = pExpr->x.pList;
119439 assert( pList!=0 );
119440 if( pList->nExpr==2 ) return 1;
119441 if( pList->nExpr==3 && sqlite3ExprIsNotTrue(pList->a[2].pExpr) ) return 1;
119493 return sqlite3ExprImpliesExpr(pParse,pE1->x.pList->a[0].pExpr,pE2,iTab);
119582 if( ExprUseXList(pExpr) && ALWAYS(pExpr->x.pList->nExpr>0) ){
119591 assert( pExpr->x.pList->nExpr==2 );
119593 bothImplyNotNullRow(pWalker, pExpr->x.pList->a[0].pExpr,
119594 pExpr->x.pList->a[1].pExpr);
119839 sqlite3WalkExprList(&w, pExpr->x.pList);
119843 assert( pExpr->pLeft->x.pList!=0 );
119844 sqlite3WalkExprList(&w, pExpr->pLeft->x.pList);
120130 nArg = pExpr->x.pList ? pExpr->x.pList->nExpr : 0;
120144 pOBList = pExpr->pLeft->x.pList;
120150 pExpr->x.pList->a[0].pExpr,0)==0
120212 SQLITE_PRIVATE void sqlite3ExprAnalyzeAggList(NameContext *pNC, ExprList *pList){
120215 if( pList ){
120216 for(pItem=pList->a, i=0; i<pList->nExpr; i++, pItem++){
120303 const ExprList *pList = pParse->pConstExpr;
120304 if( pList ){
120306 for(i=0; i<pList->nExpr; i++){
120307 if( pList->a[i].u.iConstExprReg>=iMin ){
120308 iMin = pList->a[i].u.iConstExprReg + 1;
120338 ExprList *pList = pParse->pConstExpr;
120339 for(i=0; i<pList->nExpr; i++){
120340 int iReg = pList->a[i].u.iConstExprReg;
121064 RenameToken *pList; /* List of tokens to overwrite */
121065 int nList; /* Number of tokens in pList */
121238 ExprList *pList = p->pEList;
121239 for(i=0; i<pList->nExpr; i++){
121240 if( pList->a[i].zEName && pList->a[i].fg.eEName==ENAME_NAME ){
121241 sqlite3RenameTokenRemap(pParse, 0, (void*)pList->a[i].zEName);
121331 pToken->pNext = pCtx->pList;
121332 pCtx->pList = pToken;
121392 RenameToken *pBest = pCtx->pList;
121399 for(pp=&pCtx->pList; *pp!=pBest; pp=&(*pp)->pNext);
121608 /* At this point pRename->pList contains a list of RenameToken objects
121616 while( pRename->pList ){
122036 renameTokenFree(db, sCtx.pList);
122243 renameTokenFree(db, sCtx.pList);
122357 renameTokenFree(db, sCtx.pList);
125906 SrcList *pList = pSelect->pSrc;
125908 if( NEVER(pList==0) ) return WRC_Continue;
125909 for(i=0, pItem=pList->a; i<pList->nSrc; i++, pItem++){
125927 if( pList->a[i].fg.isUsing==0
125928 && sqlite3WalkExpr(&pFix->w, pList->a[i].u3.pOn)
125988 SrcList *pList /* The Source list to check and modify */
125991 if( pList ){
125994 s.pSrc = pList;
127001 ExprList *pList;
127003 pList = pTab->u.tab.pDfltList;
127005 || NEVER(pList==0)
127006 || NEVER(pList->nExpr<pCol->iDflt)
127008 pCol->iDflt = pList==0 ? 1 : pList->nExpr+1;
127009 pTab->u.tab.pDfltList = sqlite3ExprListAppend(pParse, pList, pExpr);
127011 sqlite3ExprDelete(pParse->db, pList->a[pCol->iDflt-1].pExpr);
127012 pList->a[pCol->iDflt-1].pExpr = pExpr;
127751 SQLITE_PRIVATE void sqlite3AddReturning(Parse *pParse, ExprList *pList){
127763 sqlite3ExprListDelete(db, pList);
127769 pRet->pReturnEL = pList;
127784 pRet->retTStep.pExprList = pList;
128124 ** Designate the PRIMARY KEY for the table. pList is a list of names
128125 ** of columns that form the primary key. If pList is NULL, then the
128143 ExprList *pList, /* List of field names to be indexed */
128159 if( pList==0 ){
128165 nTerm = pList->nExpr;
128167 Expr *pCExpr = sqlite3ExprSkipCollate(pList->a[i].pExpr);
128185 if( IN_RENAME_OBJECT && pList ){
128186 Expr *pCExpr = sqlite3ExprSkipCollate(pList->a[0].pExpr);
128193 if( pList ) pParse->iPkSortOrder = pList->a[0].fg.sortFlags;
128194 (void)sqlite3HasExplicitNulls(pParse, pList);
128201 sqlite3CreateIndex(pParse, 0, 0, 0, pList, onError, 0,
128203 pList = 0;
128207 sqlite3ExprListDelete(pParse->db, pList);
128701 ExprList *pList;
128704 pList = sqlite3ExprListAppend(pParse, 0,
128706 if( pList==0 ){
128711 sqlite3RenameTokenRemap(pParse, pList->a[0].pExpr, &pTab->iPKey);
128713 pList->a[0].fg.sortFlags = pParse->iPkSortOrder;
128716 sqlite3CreateIndex(pParse, 0, 0, 0, pList, pTab->keyConf, 0, 0, 0, 0,
128914 static void markExprListImmutable(ExprList *pList){
128915 if( pList ){
128921 sqlite3WalkExprList(&w, pList);
130221 ** If expression list pList contains an expression that was parsed with
130225 SQLITE_PRIVATE int sqlite3HasExplicitNulls(Parse *pParse, ExprList *pList){
130226 if( pList ){
130228 for(i=0; i<pList->nExpr; i++){
130229 if( pList->a[i].fg.bNulls ){
130230 u8 sf = pList->a[i].fg.sortFlags;
130249 ** pList is a list of columns to be indexed. pList will be NULL if this
130258 ExprList *pList, /* A list of columns to be indexed */
130262 int sortOrder, /* Sort order of primary key when pList==NULL */
130277 struct ExprList_item *pListItem; /* For looping over pList */
130294 if( sqlite3HasExplicitNulls(pParse, pList) ){
130442 /* If pList==0, it means this routine was called to make a primary
130446 if( pList==0 ){
130451 pList = sqlite3ExprListAppend(pParse, 0,
130453 if( pList==0 ) goto exit_create_index;
130454 assert( pList->nExpr==1 );
130455 sqlite3ExprListSetSortOrder(pList, sortOrder, SQLITE_SO_UNDEFINED);
130457 sqlite3ExprListCheckLength(pParse, pList, "index");
130464 for(i=0; i<pList->nExpr; i++){
130465 Expr *pExpr = pList->a[i].pExpr;
130478 assert( pList->nExpr + nExtraCol <= 32767 /* Fits in i16 */ );
130479 pIndex = sqlite3AllocateIndexObject(db, pList->nExpr + nExtraCol,
130494 pIndex->nKeyCol = pList->nExpr;
130519 pListItem = pList->a;
130521 pIndex->aColExpr = pList;
130522 pList = 0;
130540 pIndex->aColExpr = pList;
130541 pList = 0;
130840 sqlite3ExprListDelete(db, pList);
131022 SQLITE_PRIVATE IdList *sqlite3IdListAppend(Parse *pParse, IdList *pList, Token *pToken){
131025 if( pList==0 ){
131026 pList = sqlite3DbMallocZero(db, SZ_IDLIST(1));
131027 if( pList==0 ) return 0;
131030 pNew = sqlite3DbRealloc(db, pList, SZ_IDLIST(pList->nId+1));
131032 sqlite3IdListDelete(db, pList);
131035 pList = pNew;
131037 i = pList->nId++;
131038 pList->a[i].zName = sqlite3NameFromToken(db, pToken);
131039 if( IN_RENAME_OBJECT && pList->a[i].zName ){
131040 sqlite3RenameTokenMap(pParse, (void*)pList->a[i].zName, pToken);
131042 return pList;
131048 SQLITE_PRIVATE void sqlite3IdListDelete(sqlite3 *db, IdList *pList){
131051 if( pList==0 ) return;
131052 for(i=0; i<pList->nId; i++){
131053 sqlite3DbFree(db, pList->a[i].zName);
131055 sqlite3DbNNFreeNN(db, pList);
131059 ** Return the index in pList of the identifier named zId. Return -1
131062 SQLITE_PRIVATE int sqlite3IdListIndex(IdList *pList, const char *zName){
131064 assert( pList!=0 );
131065 for(i=0; i<pList->nId; i++){
131066 if( sqlite3StrICmp(pList->a[i].zName, zName)==0 ) return i;
131163 ** a new one. If an OOM error does occurs, then the prior value of pList
131193 SrcList *pList, /* Append to this SrcList. NULL creates a new SrcList */
131203 if( pList==0 ){
131204 pList = sqlite3DbMallocRawNN(pParse->db, SZ_SRCLIST(1));
131205 if( pList==0 ) return 0;
131206 pList->nAlloc = 1;
131207 pList->nSrc = 1;
131208 memset(&pList->a[0], 0, sizeof(pList->a[0]));
131209 pList->a[0].iCursor = -1;
131211 SrcList *pNew = sqlite3SrcListEnlarge(pParse, pList, 1, pList->nSrc);
131213 sqlite3SrcListDelete(db, pList);
131216 pList = pNew;
131219 pItem = &pList->a[pList->nSrc-1];
131232 return pList;
131238 SQLITE_PRIVATE void sqlite3SrcListAssignCursors(Parse *pParse, SrcList *pList){
131241 assert( pList || pParse->db->mallocFailed );
131242 if( ALWAYS(pList) ){
131243 for(i=0, pItem=pList->a; i<pList->nSrc; i++, pItem++){
131283 SQLITE_PRIVATE void sqlite3SrcListDelete(sqlite3 *db, SrcList *pList){
131287 if( pList==0 ) return;
131288 for(pItem=pList->a, i=0; i<pList->nSrc; i++, pItem++){
131313 sqlite3DbNNFreeNN(db, pList);
131496 SQLITE_PRIVATE void sqlite3SrcListFuncArgs(Parse *pParse, SrcList *p, ExprList *pList){
131502 pItem->u1.pFuncArg = pList;
131505 sqlite3ExprListDelete(pParse->db, pList);
132925 pLhs->x.pList = sqlite3ExprListDup(db, pEList, 0);
136100 if( !pExpr->x.pList ){
136103 nExpr = pExpr->x.pList->nExpr;
136125 Expr *pEscape = pExpr->x.pList->a[2].pExpr;
138411 ExprList *pList = 0; /* Changes list if ON UPDATE CASCADE */
138488 pList = sqlite3ExprListAppend(pParse, pList, pNew);
138489 sqlite3ExprListSetName(pParse, pList, &tFromCol, 0);
138539 pStep->pExprList = sqlite3ExprListDup(db, pList, EXPRDUP_REDUCE);
138552 sqlite3ExprListDelete(db, pList);
139582 ExprList *pList = 0; /* List of VALUES() to be inserted */
139614 pList = pSelect->pEList;
139655 sqlite3TreeViewInsert(pParse->pWith, pTabList, pColumn, pSelect, pList,
139696 assert( pList==0 );
139868 if( pList ){
139869 nColumn = pList->nExpr;
139870 if( sqlite3ResolveExprListNames(&sNC, pList) ){
140090 Expr *pX = pList->a[k].pExpr;
140121 sqlite3ExprCode(pParse, pList->a[ipkColumn].pExpr, regCols);
140173 Expr *pIpk = pList->a[ipkColumn].pExpr;
140178 sqlite3ExprCode(pParse, pList->a[ipkColumn].pExpr, regRowid);
140314 sqlite3ExprListDelete(db, pList);
149204 if( p->x.pList ){
149206 for(i=0; i<p->x.pList->nExpr; i++){
149207 sqlite3SetJoinExpr(p->x.pList->a[i].pExpr, iTable, joinFlag);
149242 if( p->x.pList ){
149244 for(i=0; i<p->x.pList->nExpr; i++){
149245 unsetJoinExpr(p->x.pList->a[i].pExpr, iTable, nullable);
149331 IdList *pList = pRight->u3.pUsing;
149333 assert( pList!=0 );
149334 for(j=0; j<pList->nId; j++){
149343 zName = pList->a[j].zName;
150359 ExprList *pList, /* Form the KeyInfo object from this ExprList */
150360 int iStart, /* Begin with this column of pList */
150369 nExpr = pList->nExpr;
150373 for(i=iStart, pItem=pList->a+iStart; i<nExpr; i++, pItem++){
152641 substExprList(pSubst, pExpr->x.pList);
152656 ExprList *pList /* List to scan and in which to make substitutes */
152659 if( pList==0 ) return;
152660 for(i=0; i<pList->nExpr; i++){
152661 pList->a[i].pExpr = substExpr(pSubst, pList->a[i].pExpr);
152844 ExprList *pList;
152848 pList = p->pEList;
152849 for(ii=0; ii<pList->nExpr; ii++){
152852 assert( pList->a[ii].pExpr!=0 );
152853 aff = sqlite3ExprAffinity(pList->a[ii].pExpr);
153923 const ExprList *pList = pSel->pEList;
153924 assert( pList!=0 );
153925 for(ii=0; ii<pList->nExpr; ii++){
153926 CollSeq *pColl = sqlite3ExprCollSeq(pParse, pList->a[ii].pExpr);
154094 ExprList *pList = pSub->pOrderBy;
154095 for(j=0; j<pList->nExpr; j++){
154096 u16 iCol = pList->a[j].u.x.iOrderByCol;
154147 pEList = pFunc->x.pList;
155285 sqlite3ExprAnalyzeAggList(pNC, pExpr->x.pList);
155289 sqlite3ExprAnalyzeAggList(pNC, pExpr->pLeft->x.pList);
155433 if( pE->x.pList==0 || pE->x.pList->nExpr!=1 ){
155438 KeyInfo *pKeyInfo = sqlite3KeyInfoFromExprList(pParse, pE->x.pList,0,0);
155453 pOBList = pFunc->pFExpr->pLeft->x.pList;
155460 assert( pFunc->pFExpr->x.pList!=0 );
155461 nExtra += pFunc->pFExpr->x.pList->nExpr;
155464 nExtra += pFunc->pFExpr->x.pList->nExpr;
155488 ExprList *pList;
155491 pList = pF->pFExpr->x.pList;
155504 nArg = pList->nExpr;
155512 assert( pF->pFExpr->pLeft->x.pList!=0 );
155513 nKey = pF->pFExpr->pLeft->x.pList->nExpr;
155537 pList ? pList->nExpr : 0);
155580 ExprList *pList;
155584 pList = pF->pFExpr->x.pList;
155612 assert( pList!=0 );
155613 nArg = pList->nExpr;
155618 pOBList = pF->pFExpr->pLeft->x.pList;
155642 sqlite3ExprCodeExprList(pParse, pList, regDistinct, 0, SQLITE_ECEL_DUP);
155652 }else if( pList ){
155653 nArg = pList->nExpr;
155656 sqlite3ExprCodeExprList(pParse, pList, regAgg, 0, SQLITE_ECEL_DUP);
155661 if( pF->iDistinct>=0 && pList ){
155666 pF->iDistinct, addrNext, pList, regDistinct);
155681 assert( pList!=0 ); /* pList!=0 if pF->pFunc has NEEDCOLL */
155682 for(j=0, pItem=pList->a; !pColl && j<nArg; j++, pItem++){
155904 if( pExpr->x.pList!=0 ) return 0; /* Must be count(*) */
157233 && pAggInfo->aFunc[0].pFExpr->x.pList!=0
157235 Expr *pExpr = pAggInfo->aFunc[0].pFExpr->x.pList->a[0].pExpr;
157610 pDistinct = pAggInfo->aFunc[0].pFExpr->x.pList;
157979 Trigger *pList; /* List of triggers to return */
157985 pList = pTab->pTrigger;
157993 pTrig->pNext = pList;
157994 pList = pTrig;
158004 pTrig->pNext = pList;
158005 pList = pTrig;
158010 if( pList ){
158013 for(pX=pList; pX; pX=pX->pNext){
158020 return pList;
158740 Trigger *pList = 0;
158743 pList = sqlite3TriggerList(pParse, pTab);
158744 assert( pList==0 || IsVirtual(pTab)==0
158745 || (pList->bReturning && pList->pNext==0) );
158746 if( pList!=0 ){
158747 p = pList;
158753 ** only TEMP triggers are allowed. Truncate the pList so that it
158755 if( pList==pTab->pTrigger ){
158756 pList = 0;
158761 p = pList;
158794 return (mask ? pList : 0);
158832 /* The input list pList is the list of result set terms from a RETURNING
158835 ** This routine makes a copy of the pList, and at the same time expands
158840 ExprList *pList, /* The arguments to RETURNING */
158847 for(i=0; i<pList->nExpr; i++){
158848 Expr *pOldExpr = pList->a[i].pExpr;
158866 if( !db->mallocFailed && ALWAYS(pList->a[i].zEName!=0) ){
158868 pItem->zEName = sqlite3DbStrDup(db, pList->a[i].zEName);
158869 pItem->fg.eEName = pList->a[i].fg.eEName;
159691 ExprList *pList = 0;
159731 pList = sqlite3ExprListAppend(pParse, pList, pNew);
159736 pList = sqlite3ExprListAppend(pParse, pList, exprRowColumn(pParse, i));
159741 pList = sqlite3ExprListAppend(pParse, 0, sqlite3PExpr(pParse,TK_ROW,0,0));
159751 pList = sqlite3ExprListAppend(pParse, pList,
159756 pSelect = sqlite3SelectNew(pParse, pList,
160723 ExprList *pList;
160742 pList = sqlite3ExprListAppend(pParse, 0, pRow);
160746 pList = sqlite3ExprListAppend(pParse, pList,
160752 pList = sqlite3ExprListAppend(pParse, pList, pRowExpr);
160756 updateFromSelect(pParse, ephemTab, pPk, pList, pSrc, pWhere, 0, 0);
160757 sqlite3ExprListDelete(db, pList);
164271 pOrigLhs = pNew->pLeft->x.pList;
164294 pNew->pLeft->x.pList = pLhs;
165009 const ExprList *pList;
165011 pList = p->x.pList;
165012 assert( nReg<=pList->nExpr );
165014 sqlite3ExprCode(pParse, pList->a[i].pExpr, iReg+i);
165331 assert( iFld<=pLeft->x.pList->nExpr );
165332 pCompare->pLeft = pLeft->x.pList->a[iFld-1].pExpr;
166810 ExprList *pList; /* List of operands to the LIKE operator */
166826 pList = pExpr->x.pList;
166827 pLeft = pList->a[1].pExpr;
166829 pRight = sqlite3ExprSkipCollate(pList->a[0].pExpr);
167033 ExprList *pList;
167038 pList = pExpr->x.pList;
167039 if( pList==0 || pList->nExpr!=2 ){
167050 pCol = pList->a[1].pExpr;
167054 *ppRight = pList->a[0].pExpr;
167069 pCol = pList->a[0].pExpr;
167086 *ppRight = pList->a[1].pExpr;
167536 ExprList *pList = 0; /* The RHS of the IN operator */
167547 pList = sqlite3ExprListAppend(pWInfo->pParse, pList, pDup);
167557 pNew->x.pList = pList;
167564 sqlite3ExprListDelete(db, pList);
167706 pExpr = pExpr->x.pList->a[0].pExpr;
167787 pTerm->prereqRight = sqlite3WhereExprListUsage(pMaskSet, pExpr->x.pList);
167794 || pExpr->x.pList!=0
167835 pLeft = pLeft->x.pList->a[pTerm->u.x.iField-1].pExpr;
167915 ExprList *pList;
167919 pList = pExpr->x.pList;
167920 assert( pList!=0 );
167921 assert( pList->nExpr==2 );
167927 sqlite3ExprDup(db, pList->a[i].pExpr, 0));
168013 pLeft = pExpr->x.pList->a[1].pExpr;
168456 assert( p->x.pList==0 );
168460 }else if( p->x.pList ){
168461 mask |= sqlite3WhereExprListUsage(pMaskSet, p->x.pList);
168485 SQLITE_PRIVATE Bitmask sqlite3WhereExprListUsage(WhereMaskSet *pMaskSet, ExprList *pList){
168488 if( pList ){
168489 for(i=0; i<pList->nExpr; i++){
168490 mask |= sqlite3WhereExprUsage(pMaskSet, pList->a[i].pExpr);
168903 inexpr.pLeft = pX->pLeft->x.pList->a[iField].pExpr;
169147 ** This function searches pList for an entry that matches the iCol-th column
169150 ** If such an expression is found, its index in pList->a[] is returned. If
169155 ExprList *pList, /* Expression list to search */
169163 for(i=0; i<pList->nExpr; i++){
169164 Expr *p = sqlite3ExprSkipCollateAndLikely(pList->a[i].pExpr);
169170 CollSeq *pColl = sqlite3ExprNNCollSeq(pParse, pList->a[i].pExpr);
170911 ExprList *pList, /* The value list on the RHS of "x IN (v1,v2,v3,...)" */
170923 for(i=0; rc==SQLITE_OK && i<pList->nExpr; i++){
170925 rc = whereEqualScanEst(pParse, pBuilder, pList->a[i].pExpr, &nEst);
171678 assert( pOpExpr->x.pList->nExpr>=2 );
171682 Expr *pRHS = pOpExpr->x.pList->a[0].pExpr;
171735 pLhs = pTerm->pExpr->pLeft->x.pList->a[i].pExpr;
171740 pRhs = pRhs->x.pList->a[i].pExpr;
171930 }else if( ALWAYS(pExpr->x.pList && pExpr->x.pList->nExpr) ){
171932 nIn = sqlite3LogEst(pExpr->x.pList->nExpr);
172069 rc = whereInScanEst(pParse, pBuilder, pExpr->x.pList, &nOut);
177104 static Window *windowFind(Parse *pParse, Window *pList, const char *zName){
177106 for(p=pList; p; p=p->pNextWin){
177117 ** for a window function within a SELECT statement. Argument pList is a
177124 ** search list pList for a matching WINDOW definition, and update pWin
177134 Window *pList, /* List of named windows for this SELECT */
177139 Window *p = windowFind(pParse, pList, pWin->zName);
177150 sqlite3WindowChain(pParse, pWin, pList);
177363 ** expression list pList. Return a pointer to the result list.
177367 ExprList *pList, /* List to which to append. Might be NULL */
177373 int nInit = pList ? pList->nExpr : 0;
177391 pList = sqlite3ExprListAppend(pParse, pList, pDup);
177392 if( pList ) pList->a[nInit+i].fg.sortFlags = pAppend->a[i].fg.sortFlags;
177395 return pList;
177513 pArgs = pWin->pOwner->x.pList;
177747 SQLITE_PRIVATE void sqlite3WindowChain(Parse *pParse, Window *pWin, Window *pList){
177750 Window *pExist = windowFind(pParse, pList, pWin->zBase);
177909 ExprList *pList;
177912 pList = pWin->pOwner->x.pList;
177913 pKeyInfo = sqlite3KeyInfoFromExprList(pParse, pList, 0, 0);
178001 const ExprList *pList;
178003 pList = pWin->pOwner->x.pList;
178004 return (pList ? pList->nExpr : 0);
178164 assert( pWin->bExprArgs || !nArg ||nArg==pWin->pOwner->x.pList->nExpr );
178165 assert( pWin->bExprArgs || nArg ||pWin->pOwner->x.pList==0 );
178204 nArg = pWin->pOwner->x.pList->nExpr;
178206 sqlite3ExprCodeExprList(pParse, pWin->pOwner->x.pList, regArg, 0, 0);
178219 pColl = sqlite3ExprNNCollSeq(pParse, pWin->pOwner->x.pList->a[0].pExpr);
178430 int nArg = pWin->pOwner->x.pList->nExpr;
184247 ExprList *pList = sqlite3ExprListAppend(pParse, yymsp[-3].minor.yy14, yymsp[-1].minor.yy454);
184250 yymsp[-4].minor.yy454->x.pList = pList;
184251 if( ALWAYS(pList->nExpr) ){
184252 yymsp[-4].minor.yy454->flags |= pList->a[0].pExpr->flags & EP_Propagate;
184255 sqlite3ExprListDelete(pParse->db, pList);
184276 ExprList *pList;
184279 pList = sqlite3ExprListAppend(pParse,0, yymsp[0].minor.yy454);
184280 pList = sqlite3ExprListAppend(pParse,pList, yymsp[-2].minor.yy454);
184281 yymsp[-2].minor.yy454 = sqlite3ExprFunction(pParse, pList, &yymsp[-1].minor.yy0, 0);
184288 ExprList *pList;
184291 pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy454);
184292 pList = sqlite3ExprListAppend(pParse,pList, yymsp[-4].minor.yy454);
184293 pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy454);
184294 yymsp[-4].minor.yy454 = sqlite3ExprFunction(pParse, pList, &yymsp[-3].minor.yy0, 0);
184346 ExprList *pList = sqlite3ExprListAppend(pParse, 0, yymsp[-2].minor.yy454);
184347 pList = sqlite3ExprListAppend(pParse, pList, yymsp[0].minor.yy454);
184348 yylhsminor.yy454 = sqlite3ExprFunction(pParse, pList, &yymsp[-1].minor.yy0, 0);
184358 ExprList *pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy454);
184359 pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy454);
184362 yymsp[-4].minor.yy454->x.pList = pList;
184364 sqlite3ExprListDelete(pParse->db, pList);
184409 int nExpr = yymsp[-4].minor.yy454->pLeft->x.pList->nExpr;
184416 yymsp[-4].minor.yy454->x.pList = yymsp[-1].minor.yy14;
184458 yymsp[-4].minor.yy454->x.pList = yymsp[-1].minor.yy454 ? sqlite3ExprListAppend(pParse,yymsp[-2].minor.yy14,yymsp[-1].minor.yy454) : yymsp[-2].minor.yy14;
193634 sqlite3_int64 iDocid; /* Current docid (if pList!=0) */
193635 int bFreeList; /* True if pList should be sqlite3_free()d */
193636 char *pList; /* Pointer to position list following iDocid */
196379 ** Argument pList points to a position list nList bytes in size. This
196383 ** of the entries from pList at position 0, and terminated by an 0x00 byte.
196388 char *pList, /* Position list (no 0x00 term) */
196389 int nList, /* Size of pList in bytes */
196394 char *p = pList;
196395 char *pEnd = &pList[nList];
197875 ** Arguments pList/nList contain the doclist for token iToken of phrase p.
197878 ** This function assumes that pList points to a buffer allocated using
197886 Fts3Phrase *p, /* Phrase to merge pList/nList into */
197887 int iToken, /* Token pList/nList corresponds to */
197888 char *pList, /* Pointer to doclist */
197889 int nList /* Number of bytes in pList */
197894 if( pList==0 ){
197901 p->doclist.aAll = pList;
197906 sqlite3_free(pList);
197919 pRight = pList;
197925 pLeft = pList;
197980 ** means that the phrase does not appear in the current row, doclist.pList
197990 char *aFree = (pPhrase->doclist.bFreeList ? pPhrase->doclist.pList : 0);
197997 char *pList;
197999 int rc = sqlite3Fts3DeferredTokenList(pDeferred, &pList, &nList);
198002 if( pList==0 ){
198005 pPhrase->doclist.pList = 0;
198010 aPoslist = pList;
198014 char *aOut = pList;
198021 aPoslist = pList;
198026 pPhrase->doclist.pList = 0;
198038 pPhrase->doclist.pList = aPoslist;
198050 p2 = pPhrase->doclist.pList;
198053 p1 = pPhrase->doclist.pList;
198064 pPhrase->doclist.pList = aOut;
198068 pPhrase->doclist.nList = (int)(aOut - pPhrase->doclist.pList);
198071 pPhrase->doclist.pList = 0;
198078 if( pPhrase->doclist.pList!=aFree ) sqlite3_free(aFree);
198277 pDL->pList = pIter;
198279 pDL->nList = (int)(pIter - pDL->pList);
198302 char *pList;
198328 p->pList = pPhrase->doclist.pList;
198338 pTab, pToken->pSegcsr, &p->iDocid, &p->pList, &p->nList
198340 if( p->pList==0 ) *pbEof = 1;
198358 ** the Fts3Doclist.pList and nList fields.
198383 &pDL->iDocid, &pDL->pList, &pDL->nList
198385 if( pDL->pList==0 ) bEof = 1;
198429 memcpy(aDoclist, a[p->nToken-1].pList, nByte+1);
198434 char *pL = a[i].pList;
198445 pDL->pList = aDoclist;
198483 pDL->pList = pDL->pNextDocid;
198773 char *pList = 0;
198774 rc = fts3TermSelect(pTab, pToken, pTC->iCol, &nList, &pList);
198775 assert( rc==SQLITE_OK || pList==0 );
198778 pTab, pTC->pPhrase, pTC->iToken,pList,nList
198859 sqlite3_free(pPhrase->doclist.pList);
198861 pPhrase->doclist.pList = 0;
198902 assert( pPhrase->doclist.pList );
198904 p2 = pOut = pPhrase->doclist.pList;
198909 nNew = (int)(pOut - pPhrase->doclist.pList) - 1;
198912 assert( pPhrase->doclist.pList[nNew]=='\0' );
198913 memset(&pPhrase->doclist.pList[nNew], 0, pPhrase->doclist.nList - nNew);
198916 *paPoslist = pPhrase->doclist.pList;
198940 ** FTs3Expr.pPhrase->doclist.nList (length of pList in bytes)
198941 ** FTs3Expr.pPhrase->doclist.pList (pointer to position list)
199012 memset(pDl->pList, 0, pDl->nList);
199019 memset(pDl->pList, 0, pDl->nList);
199097 ** (Fts3Expr->pPhrase.doclist.pList/nList) for each phrase in the expression.
199148 char *aPoslist = p->pPhrase->doclist.pList;
199157 aPoslist = pExpr->pRight->pPhrase->doclist.pList;
199253 pExpr->iDocid==pCsr->iPrevId && pExpr->pPhrase->doclist.pList
199260 bHit = (pPhrase->doclist.pList!=0);
199430 ** found in Fts3Expr.pPhrase->doclist.pList for each of the phrase
199436 if( pPhrase && pPhrase->doclist.pList ){
199438 char *p = pPhrase->doclist.pList;
199667 pIter = pPhrase->doclist.pList;
204097 PendingList *pList; /* Doclist is assembled here */
204741 static void fts3PendingListDelete(PendingList *pList){
204742 sqlite3_free(pList);
204756 PendingList *pList;
204759 pList = (PendingList *)fts3HashFind(pHash, zToken, nToken);
204760 if( pList ){
204761 assert( (i64)pList->nData+(i64)nToken+(i64)sizeof(Fts3HashElem)
204763 p->nPendingData -= (int)(pList->nData + nToken + sizeof(Fts3HashElem));
204765 if( fts3PendingListAppend(&pList, p->iPrevDocid, iCol, iPos, &rc) ){
204766 if( pList==fts3HashInsert(pHash, zToken, nToken, pList) ){
204771 sqlite3_free(pList);
204776 assert( (i64)p->nPendingData + pList->nData + nToken
204778 p->nPendingData += (int)(pList->nData + nToken + sizeof(Fts3HashElem));
204906 PendingList *pList = (PendingList *)fts3HashData(pElem);
204907 fts3PendingListDelete(pList);
205338 PendingList *pList = (PendingList *)fts3HashData(pElem);
205339 int nCopy = pList->nData+1;
205354 memcpy(aCopy, pList->aData, nCopy);
206628 char *pList = *ppList;
206630 char *pEnd = &pList[nList];
206632 char *p = pList;
206640 nList = (int)(p - pList);
206644 nList -= (int)(p - pList);
206645 pList = p;
206649 p = &pList[1];
206653 if( bZero && (pEnd - &pList[nList])>0){
206654 memset(&pList[nList], 0, pEnd - &pList[nList]);
206656 *ppList = pList;
206669 char *pList,
206682 memcpy(pMsr->aBuffer, pList, nList);
206714 char *pList;
206719 rc = fts3SegReaderNextDocid(p, apSegment[0], &pList, &nList);
206733 rc = fts3MsrBufferData(pMsr, pList, (i64)nList+1);
206736 pList
206740 fts3ColumnFilter(pMsr->iColFilter, 1, &pList, &nList);
206744 *paPoslist = pList;
206986 char *pList = 0;
206990 fts3SegReaderNextDocid(p, apSegment[0], &pList, &nList);
207001 fts3ColumnFilter(pFilter->iCol, 0, &pList, &nList);
207027 nWrite = sqlite3Fts3FirstFilter(iDelta, pList, nList, a);
207036 memcpy(&pCsr->aBuffer[nDoclist], pList, nList);
209487 fts3PendingListDelete(pDef->pList);
209488 pDef->pList = 0;
209501 fts3PendingListDelete(pDef->pList);
209549 fts3PendingListAppend(&pDef->pList, iDocid, i, iPos, &rc);
209559 if( pDef->pList ){
209560 rc = fts3PendingListAppendVarint(&pDef->pList, 0);
209580 if( p->pList==0 ){
209584 pRet = (char *)sqlite3_malloc64(p->pList->nData);
209587 nSkip = sqlite3Fts3GetVarint(p->pList->aData, &dummy);
209588 *pnData = p->pList->nData - nSkip;
209591 memcpy(pRet, &p->pList->aData[nSkip], *pnData);
209908 char *pList; /* Pointer to start of phrase position list */
210322 pPhrase->pList = pCsr;
210334 pPhrase->pList==0 && pPhrase->pHead==0 && pPhrase->pTail==0
210713 char *pIter = pPhrase->doclist.pList;
211386 char *pList; /* Position-list */
211387 i64 iPos; /* Position just read from pList */
211406 char *pList; /* Pointer to position list for phrase */
211411 rc = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol, &pList);
211413 if( pList ){
211414 fts3GetDeltaPosition(&pList, &iPos);
211421 pT->pList = pList;
211539 if( pT->pList && (pT->iPos-pT->iOff)<iMinPos ){
211550 if( 0==(0xFE&*pTerm->pList) ){
211551 pTerm->pList = 0;
211553 fts3GetDeltaPosition(&pTerm->pList, &pTerm->iPos);
223440 static GeoSegment *geopolySortSegmentsByYAndC(GeoSegment *pList){
223445 while( pList ){
223446 p = pList;
223447 pList = pList->pNext;
227210 sqlite3_stmt *pList = 0;
227215 p->rc = prepareFreeAndCollectError(p->dbMain, &pList, &p->zErrmsg,
227221 while( p->rc==SQLITE_OK && SQLITE_ROW==sqlite3_step(pList) ){
227222 const char *zIdx = (const char*)sqlite3_column_text(pList, 1);
227223 int bPartial = sqlite3_column_int(pList, 4);
227249 rbuFinalize(p, pList);
235727 static void sessionDeleteTable(sqlite3_session *pSession, SessionTable *pList){
235731 for(pTab=pList; pTab; pTab=pNext){
239052 SessionTable *pList; /* List of tables in current patch */
239381 for(pTab = pGrp->pList; pTab; pTab=pTab->pNext){
239423 for(ppNew=&pGrp->pList; *ppNew; ppNew=&(*ppNew)->pNext);
239526 if( pGrp->pList==0 ){
239601 ** hash tables attached to the SessionTable objects in list p->pList.
239603 for(pTab=pGrp->pList; rc==SQLITE_OK && pTab; pTab=pTab->pNext){
239665 if( pGrp->pList==0 && arg>=0 ){
239689 if( pGrp->pList || pGrp->db ){
239796 sessionDeleteTable(0, pGrp->pList);
240011 for(pTab=p->grp.pList; pTab; pTab=pTab->pNext){
240198 sessionDeleteTable(0, p->grp.pList);
249941 Fts5HashEntry *pList;
249967 pList = 0;
249969 pList = fts5HashEntryMerge(pList, ap[i]);
249973 *ppSorted = pList;
252331 const u8 *pList = 0;
252336 sqlite3Fts5HashScanEntry(p->pHash, &zTerm, &nTerm, &pList, &nList);
252337 if( pList==0 ) goto next_none_eof;
252338 pIter->pLeaf->p = (u8*)pList;
252343 pIter->iLeafOffset = fts5GetVarint(pList, (u64*)&pIter->iRowid);
252406 const u8 *pList = 0;
252413 sqlite3Fts5HashScanEntry(p->pHash, &zTerm, &nTerm, &pList, &nList);
252415 if( pList==0 ){
252419 pIter->pLeaf->p = (u8*)pList;
252424 pIter->iLeafOffset = fts5GetVarint(pList, (u64*)&pIter->iRowid);
252942 const u8 *pList = 0;
252945 sqlite3Fts5HashScanEntry(p->pHash, (const char**)&z, &n, &pList, &nList);
252946 if( pList ){
252949 pLeaf->p = (u8*)pList;