Home | History | Annotate | Download | only in dist

Lines Matching refs:pSub

48473   Mem *pSub = 0;                       /* Memory cell hold array of subprogs */
48510 pSub = &p->aMem[9];
48511 if( pSub->flags&MEM_Blob ){
48512 /* On the first call to sqlite3_step(), pSub will hold a NULL. It is
48514 nSub = pSub->n/sizeof(Vdbe*);
48515 apSub = (SubProgram **)pSub->z;
48574 if( j==nSub && SQLITE_OK==sqlite3VdbeMemGrow(pSub, nByte, 1) ){
48575 apSub = (SubProgram **)pSub->z;
48577 pSub->flags |= MEM_Blob;
48578 pSub->n = nSub*sizeof(SubProgram*);
81809 Select *pSub; /* The inner query or "subquery" */
81814 int iParent; /* VDBE cursor number of the pSub result set temp table */
81829 pSub = pSubitem->pSelect;
81830 assert( pSub!=0 );
81833 pSubSrc = pSub->pSrc;
81840 if( pSub->pLimit && p->pLimit ) return 0; /* Restriction (13) */
81841 if( pSub->pOffset ) return 0; /* Restriction (14) */
81842 if( p->pRightmost && pSub->pLimit && pSub->pOrderBy ){
81846 if( ((pSub->selFlags & SF_Distinct)!=0 || pSub->pLimit)
81853 if( p->pOrderBy && pSub->pOrderBy ){
81856 if( isAgg && pSub->pOrderBy ) return 0; /* Restriction (16) */
81857 if( pSub->pLimit && p->pWhere ) return 0; /* Restriction (19) */
81900 if( pSub->pPrior ){
81901 if( pSub->pOrderBy ){
81907 for(pSub1=pSub; pSub1; pSub1=pSub1->pPrior){
81967 for(pSub=pSub->pPrior; pSub; pSub=pSub->pPrior){
81995 pSub = pSub1 = pSubitem->pSelect;
82040 for(pParent=p; pParent; pParent=pParent->pPrior, pSub=pSub->pPrior){
82043 pSubSrc = pSub->pSrc; /* FROM clause of subquery */
82112 substExprList(db, pParent->pEList, iParent, pSub->pEList);
82114 substExprList(db, pParent->pGroupBy, iParent, pSub->pEList);
82115 pParent->pHaving = substExpr(db, pParent->pHaving, iParent, pSub->pEList);
82117 if( pSub->pOrderBy ){
82119 pParent->pOrderBy = pSub->pOrderBy;
82120 pSub->pOrderBy = 0;
82122 substExprList(db, pParent->pOrderBy, iParent, pSub->pEList);
82124 if( pSub->pWhere ){
82125 pWhere = sqlite3ExprDup(db, pSub->pWhere, 0);
82133 pParent->pHaving = substExpr(db, pParent->pHaving, iParent, pSub->pEList);
82135 sqlite3ExprDup(db, pSub->pHaving, 0));
82137 pParent->pGroupBy = sqlite3ExprListDup(db, pSub->pGroupBy, 0);
82139 pParent->pWhere = substExpr(db, pParent->pWhere, iParent, pSub->pEList);
82146 pParent->selFlags |= pSub->selFlags & SF_Distinct;
82154 if( pSub->pLimit ){
82155 pParent->pLimit = pSub->pLimit;
82156 pSub->pLimit = 0;
82850 Select *pSub = pItem->pSelect;
82853 if( pSub==0 || pItem->isPopulated ) continue;
82865 isAggSub = (pSub->selFlags & SF_Aggregate)!=0;
82875 sqlite3Select(pParse, pSub, &dest);