Lines Matching refs:pSub

72941   Mem *pSub = 0;                       /* Memory cell hold array of subprogs */
72979 pSub = &p->aMem[9];
72980 if( pSub->flags&MEM_Blob ){
72983 nSub = pSub->n/sizeof(Vdbe*);
72984 apSub = (SubProgram **)pSub->z;
73041 if( j==nSub && SQLITE_OK==sqlite3VdbeMemGrow(pSub, nByte, nSub!=0) ){
73042 apSub = (SubProgram **)pSub->z;
73044 pSub->flags |= MEM_Blob;
73045 pSub->n = nSub*sizeof(SubProgram*);
74327 SubProgram *pSub, *pNext;
74330 for(pSub=p->pProgram; pSub; pSub=pNext){
74331 pNext = pSub->pNext;
74332 vdbeFreeOpArray(db, pSub->aOp, pSub->nOp);
74333 sqlite3DbFree(db, pSub);
90405 Select *pSub = p->pSrc->a[0].pSelect;
90407 assert( pSub->pPrior && pSub->pOrderBy==0 );
90408 pSub->pOrderBy = p->pOrderBy;
90502 Select *pSub = p->pSrc->a[0].pSelect;
90503 p->pOrderBy = pSub->pOrderBy;
90504 pSub->pOrderBy = 0;
119633 Select *pSub; /* The inner query or "subquery" */
119653 pSub = pSubitem->pSelect;
119654 assert( pSub!=0 );
119666 pSubSrc = pSub->pSrc;
119673 if( pSub->pLimit && p->pLimit ) return 0; /* Restriction (13) */
119674 if( pSub->pOffset ) return 0; /* Restriction (14) */
119675 if( (p->selFlags & SF_Compound)!=0 && pSub->pLimit ){
119679 if( pSub->selFlags & SF_Distinct ) return 0; /* Restriction (5) */
119680 if( pSub->pLimit && (pSrc->nSrc>1 || isAgg) ){
119686 if( p->pOrderBy && pSub->pOrderBy ){
119689 if( isAgg && pSub->pOrderBy ) return 0; /* Restriction (16) */
119690 if( pSub->pLimit && p->pWhere ) return 0; /* Restriction (19) */
119691 if( pSub->pLimit && (p->selFlags & SF_Distinct)!=0 ){
119694 testcase( pSub->selFlags & SF_Recursive );
119695 testcase( pSub->selFlags & SF_MinMaxAgg );
119696 if( pSub->selFlags & (SF_Recursive|SF_MinMaxAgg) ){
119699 if( (p->selFlags & SF_Recursive) && pSub->pPrior ){
119744 if( pSub->pPrior ){
119745 if( pSub->pOrderBy ){
119751 for(pSub1=pSub; pSub1; pSub1=pSub1->pPrior){
119754 assert( pSub->pSrc!=0 );
119755 assert( pSub->pEList->nExpr==pSub1->pEList->nExpr );
119776 pSub->zSelName, pSub, iFrom));
119817 for(pSub=pSub->pPrior; pSub; pSub=pSub->pPrior){
119829 sqlite3SelectSetName(pNew, pSub->zSelName);
119852 pSub = pSub1 = pSubitem->pSelect;
119897 for(pParent=p; pParent; pParent=pParent->pPrior, pSub=pSub->pPrior){
119900 pSubSrc = pSub->pSrc; /* FROM clause of subquery */
119969 if( pSub->pOrderBy ){
119980 ExprList *pOrderBy = pSub->pOrderBy;
119985 assert( pSub->pPrior==0 );
119987 pSub->pOrderBy = 0;
119989 pWhere = sqlite3ExprDup(db, pSub->pWhere, 0);
119995 sqlite3ExprDup(db, pSub->pHaving, 0), pParent->pHaving
119998 pParent->pGroupBy = sqlite3ExprListDup(db, pSub->pGroupBy, 0);
120003 substSelect(pParse, pParent, iParent, pSub->pEList, 0);
120009 pParent->selFlags |= pSub->selFlags & SF_Distinct;
120017 if( pSub->pLimit ){
120018 pParent->pLimit = pSub->pLimit;
120019 pSub->pLimit = 0;
120688 Select *pSub = pFrom->pSelect;
120696 if( pSub==0 || (pSub->selFlags & SF_NestedFrom)==0 ){
120697 pSub = 0;
120711 if( zTName && pSub
120712 && sqlite3MatchSpanName(pSub->pEList->a[j].zSpan, 0, zTName, 0)==0
120765 if( pSub ){
120766 pX->zSpan = sqlite3DbStrDup(db, pSub->pEList->a[j].zSpan);
121188 Select *pSub = pItem->pSelect;
121191 if( pSub==0 ) continue;
121195 if( pTab->nCol!=pSub->pEList->nExpr ){
121197 pTab->nCol, pTab->zName, pSub->pEList->nExpr);
121201 isAggSub = (pSub->selFlags & SF_Aggregate)!=0;
121244 Select *pSub = pItem->pSelect;
121245 if( pSub==0 ) continue;
121273 && pushDownWhereTerms(pParse, pSub, p->pWhere, pItem->iCursor)
121313 sqlite3Select(pParse, pSub, &dest);
121314 pItem->pTab->nRowLogEst = pSub->nSelectRow;
121344 sqlite3Select(pParse, pSub, &dest);
121345 pItem->pTab->nRowLogEst = pSub->nSelectRow;
187861 static void fts5ExprAddChildren(Fts5ExprNode *p, Fts5ExprNode *pSub){
187862 if( p->eType!=FTS5_NOT && pSub->eType==p->eType ){
187863 int nByte = sizeof(Fts5ExprNode*) * pSub->nChild;
187864 memcpy(&p->apChild[p->nChild], pSub->apChild, nByte);
187865 p->nChild += pSub->nChild;
187866 sqlite3_free(pSub);
187868 p->apChild[p->nChild++] = pSub;
192338 const u8 *pSub = pPos;
192339 int nSub = fts5IndexExtractCol(&pSub, nPos, pColset->aiCol[i]);
192341 fts5BufferAppendBlob(&rc, pBuf, nSub, pSub);