• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/ap/gpl/minidlna/sqlite-3.6.22/

Lines Matching defs:pSelect

8731   Select *pSelect;     /* NULL for tables.  Points to definition if a view. */
9049 ** Expr.x.pSelect is used if the expression is a sub-select or an expression of
9051 ** Expr.flags mask, then Expr.x.pSelect is valid. Otherwise, Expr.x.pList is
9088 ** the subtrees in Expr.x.pList or Expr.x.pSelect are always separately
9109 Select *pSelect; /* Used for sub-selects and "<expr> IN (<select>)" */
9142 #define EP_VarSelect 0x0020 /* pSelect is correlated, not constant */
9148 #define EP_xIsSelect 0x0800 /* x.pSelect is valid (otherwise x.pList is) */
9292 Select *pSelect; /* A SELECT statement used in place of a table name */
9767 * pSelect -> If this is an INSERT INTO ... SELECT ... statement, then
9794 Select *pSelect; /* SELECT statment or RHS of INSERT INTO .. SELECT ... */
58128 if( pTab && pTab->pSelect ){
58953 if( sqlite3WalkSelect(pWalker, pExpr->x.pSelect) ) return WRC_Abort;
59008 if( sqlite3WalkSelect(pWalker, pItem->pSelect) ){
59346 assert( pExpr->x.pSelect==0 );
59627 sqlite3WalkSelect(pWalker, pExpr->x.pSelect);
59700 Select *pSelect, /* The SELECT statement with the ORDER BY clause */
59708 pEList = pSelect->pEList;
59714 nc.pSrcList = pSelect->pSrc;
59768 Select *pSelect /* The SELECT statement containing the ORDER BY */
59776 pOrderBy = pSelect->pOrderBy;
59788 pSelect->pNext = 0;
59789 while( pSelect->pPrior ){
59790 pSelect->pPrior->pNext = pSelect;
59791 pSelect = pSelect->pPrior;
59793 while( pSelect && moreToDo ){
59796 pEList = pSelect->pEList;
59814 iCol = resolveOrderByTermToExprList(pParse, pSelect, pDup);
59834 pSelect = pSelect->pNext;
59848 ** the SELECT statement pSelect. If any term is reference to a
59858 Select *pSelect, /* The SELECT statement containing the clause */
59874 pEList = pSelect->pEList;
59889 ** pOrderBy is an ORDER BY or GROUP BY clause in SELECT statement pSelect.
59908 Select *pSelect, /* The SELECT statement holding pOrderBy */
59919 nResult = pSelect->pEList->nExpr;
59923 iCol = resolveAsName(pParse, pSelect->pEList, pE);
59950 return sqlite3ResolveOrderGroupBy(pParse, pSelect, pOrderBy, zType);
60029 if( pItem->pSelect ){
60032 sqlite3ResolveSelectNames(pParse, pItem->pSelect, pOuterNC);
60274 return sqlite3ExprAffinity(pExpr->x.pSelect->pEList->a[0].pExpr);
60398 aff = sqlite3CompareAffinity(pExpr->x.pSelect->pEList->a[0].pExpr, aff);
60553 ** Expr.pSelect member has a height of 1. Any other expression
60562 heightOfSelect(p->x.pSelect, &nHeight);
60854 sqlite3SelectDelete(db, p->x.pSelect);
60952 ** descended from the Expr.x.pList or Expr.x.pSelect variables).
61026 /* Fill in the pNew->x.pSelect or pNew->x.pList member. */
61028 pNew->x.pSelect = sqlite3SelectDup(db, p->x.pSelect, isReduced);
61139 pNewItem->pSelect = sqlite3SelectDup(db, pOldItem->pSelect, flags);
61594 if( pSrc->a[0].pSelect ) return 0; /* FROM is not a subquery or view */
61597 assert( pTab->pSelect==0 ); /* FROM clause is not a view */
61673 p = (ExprHasProperty(pX, EP_xIsSelect) ? pX->x.pSelect : 0);
61871 if( sqlite3Select(pParse, pExpr->x.pSelect, &dest) ){
61874 pEList = pExpr->x.pSelect->pEList;
61958 pSel = pExpr->x.pSelect;
63873 static int analyzeAggregatesInSelect(Walker *pWalker, Select *pSelect){
63877 sqlite3WalkSelect(pWalker, pSelect);
64395 if( pTab->pSelect ){
64715 if( pTab->pSelect ){
65877 if( sqlite3FixSelect(pFix, pItem->pSelect) ) return 1;
65886 Select *pSelect /* The SELECT statement to be fixed to one database */
65888 while( pSelect ){
65889 if( sqlite3FixExprList(pFix, pSelect->pEList) ){
65892 if( sqlite3FixSrcList(pFix, pSelect->pSrc) ){
65895 if( sqlite3FixExpr(pFix, pSelect->pWhere) ){
65898 if( sqlite3FixExpr(pFix, pSelect->pHaving) ){
65901 pSelect = pSelect->pPrior;
65912 if( sqlite3FixSelect(pFix, pExpr->x.pSelect) ) return 1;
65945 if( sqlite3FixSelect(pFix, pStep->pSelect) ){
66745 sqlite3SelectDelete(db, pTable->pSelect);
67647 ** If the pSelect argument is not NULL, it means that this routine
67656 Select *pSelect /* Select from a "CREATE ... AS SELECT" */
67662 if( (pEnd==0 && pSelect==0) || db->mallocFailed ){
67668 assert( !db->init.busy || !pSelect );
67725 if( p->pSelect==0 ){
67750 if( pSelect ){
67759 sqlite3Select(pParse, pSelect, &dest);
67762 pSelTab = sqlite3ResultSetOfSelect(pParse, pSelect);
67774 if( pSelect ){
67840 if( !p->pSelect ){
67843 assert( !pSelect && pCons && pEnd );
67863 Select *pSelect, /* A SELECT statement that will become the new view */
67878 sqlite3SelectDelete(db, pSelect);
67884 sqlite3SelectDelete(db, pSelect);
67892 && sqlite3FixSelect(&sFix, pSelect)
67894 sqlite3SelectDelete(db, pSelect);
67903 p->pSelect = sqlite3SelectDup(db, pSelect, EXPRDUP_REDUCE);
67904 sqlite3SelectDelete(db, pSelect);
67989 assert( pTable->pSelect );
67990 pSel = sqlite3SelectDup(db, pTable->pSelect, 0);
68037 if( pTab->pSelect ){
68250 if( isView && pTab->pSelect==0 ){
68254 if( !isView && pTab->pSelect ){
68672 if( pTab->pSelect ){
69395 if( pItem->pSelect ){
69396 sqlite3SrcListAssignCursors(pParse, pItem->pSelect->pSrc);
69415 sqlite3SelectDelete(db, pItem->pSelect);
69465 pItem->pSelect = pSubquery;
70434 if( !viewOk && pTab->pSelect ){
70459 pDup = sqlite3SelectDup(db, pView->pSelect, 0);
70468 pFrom->a[0].pSelect = pDup;
70505 Select *pSelect = NULL; /* Complete SELECT tree */
70547 pSelect = sqlite3SelectNew(pParse,pEList,pSelectSrc,pWhere,0,0,
70549 if( pSelect == 0 ) return 0;
70557 pInClause->x.pSelect = pSelect;
70564 sqlite3SelectDelete(pParse->db, pSelect);
70628 isView = pTab->pSelect!=0;
70906 if( pTab->pSelect==0 ){
73130 sqlite3SelectDelete(dbMem, pStep->pSelect);
73155 if( (db->flags&SQLITE_ForeignKeys) && !IsVirtual(pTab) && !pTab->pSelect ){
73496 Select *pSelect = 0; /* If RESTRICT, "SELECT RAISE(...)" */
73587 pSelect = sqlite3SelectNew(pParse,
73617 pStep->pSelect = sqlite3SelectDup(db, pSelect, EXPRDUP_REDUCE);
73630 sqlite3SelectDelete(db, pSelect);
74049 Select *pSelect, /* A SELECT statement to use as the data source */
74065 ** statement above, and pSelect is NULL. For the second form, pList is
74066 ** NULL and pSelect is a pointer to the select statement used to generate
74160 Select *pSelect, /* A SELECT statement to use as the data source */
74231 isView = pTab->pSelect!=0;
74264 sqlite3BeginWriteOperation(pParse, pSelect || pTrigger, iDb);
74276 if( pColumn==0 && xferOptimization(pParse, pTab, pSelect, onError, iDb) ){
74293 if( pSelect ){
74328 rc = sqlite3Select(pParse, pSelect, &dest);
74340 assert( pSelect->pEList );
74341 nColumn = pSelect->pEList->nExpr;
74505 }else if( pSelect ){
74550 assert( pSelect==0 ); /* Otherwise useTempTable is true */
74579 assert( pSelect==0 ); /* Otherwise useTempTable is true */
74614 }else if( pSelect ){
74682 }else if( pSelect ){
74732 }else if( pSelect ){
74768 sqlite3SelectDelete(db, pSelect);
74888 assert( pTab->pSelect==0 ); /* This table is not a VIEW */
75153 assert( pTab->pSelect==0 ); /* This table is not a VIEW */
75319 Select *pSelect, /* A SELECT statement to use as the data source */
75326 struct SrcList_item *pItem; /* An element of pSelect->pSrc */
75339 if( pSelect==0 ){
75356 assert(pSelect->pSrc); /* allocated even if there is no FROM clause */
75357 if( pSelect->pSrc->nSrc!=1 ){
75360 if( pSelect->pSrc->a[0].pSelect ){
75363 if( pSelect->pWhere ){
75366 if( pSelect->pOrderBy ){
75371 if( pSelect->pGroupBy ){
75374 if( pSelect->pLimit ){
75377 assert( pSelect->pOffset==0 ); /* Must be so if pLimit==0 */
75378 if( pSelect->pPrior ){
75381 if( pSelect->selFlags & SF_Distinct ){
75384 pEList = pSelect->pEList;
75398 pItem = pSelect->pSrc->a;
75411 if( pSrc->pSelect ){
79404 Select *pSelect, /* The whole SELECT statement */
79419 if( pSelect->iLimit ){
79422 if( pSelect->iOffset ){
79423 iLimit = pSelect->iOffset+1;
79425 iLimit = pSelect->iLimit;
79434 pSelect->iLimit = 0;
79916 pS = pTabList->a[j].pSelect;
79988 Select *pS = pExpr->x.pSelect;
80240 Select *pSelect /* SELECT used to determine types and collations */
80250 assert( pSelect!=0 );
80251 assert( (pSelect->selFlags & SF_Resolved)!=0 );
80252 assert( nCol==pSelect->pEList->nExpr || db->mallocFailed );
80255 sNC.pSrcList = pSelect->pSrc;
80256 a = pSelect->pEList->a;
80273 SQLITE_PRIVATE Table *sqlite3ResultSetOfSelect(Parse *pParse, Select *pSelect){
80281 sqlite3SelectPrep(pParse, pSelect, 0);
80283 while( pSelect->pPrior ) pSelect = pSelect->pPrior;
80295 selectColumnsFromExprList(pParse, pSelect->pEList, &pTab->nCol, &pTab->aCol);
80296 selectAddColumnTypeAndCollation(pParse, pTab->nCol, pTab->aCol, pSelect);
81408 substSelect(db, pExpr->x.pSelect, iTable, pEList);
81447 substSelect(db, pItem->pSelect, iTable, pEList);
81589 pSub = pSubitem->pSelect;
81755 pSub = pSub1 = pSubitem->pSelect;
81766 pSubitem->pSelect = 0;
81978 || p->pSrc->nSrc!=1 || p->pSrc->a[0].pSelect
81984 assert( pTab && !pTab->pSelect && pExpr );
82028 ** fill pTabList->a[].pSelect with a copy of the SELECT statement
82080 Select *pSel = pFrom->pSelect;
82103 if( pTab->pSelect || IsVirtual(pTab) ){
82106 assert( pFrom->pSelect==0 );
82107 pFrom->pSelect = sqlite3SelectDup(db, pTab->pSelect, 0);
82108 sqlite3WalkSelect(pWalker, pFrom->pSelect);
82289 static void sqlite3SelectExpand(Parse *pParse, Select *pSelect){
82294 sqlite3WalkSelect(&w, pSelect);
82327 Select *pSel = pFrom->pSelect;
82345 static void sqlite3SelectAddTypeInfo(Parse *pParse, Select *pSelect){
82351 sqlite3WalkSelect(&w, pSelect);
82610 Select *pSub = pItem->pSelect;
83232 if( pItem->pSelect ){
83234 sqlite3PrintSelect(pItem->pSelect, indent+10);
83499 sqlite3SelectDelete(db, pTmp->pSelect);
83658 if( pTab->pSelect && tr_tm!=TK_INSTEAD ){
83663 if( !pTab->pSelect && tr_tm==TK_INSTEAD ){
83800 ** Turn a SELECT statement (that the pSelect parameter points to) into
83806 SQLITE_PRIVATE TriggerStep *sqlite3TriggerSelectStep(sqlite3 *db, Select *pSelect){
83809 sqlite3SelectDelete(db, pSelect);
83813 pTriggerStep->pSelect = pSelect;
83854 Select *pSelect, /* A SELECT statement that supplies values */
83859 assert(pEList == 0 || pSelect == 0);
83860 assert(pEList != 0 || pSelect != 0 || db->mallocFailed);
83864 pTriggerStep->pSelect = sqlite3SelectDup(db, pSelect, EXPRDUP_REDUCE);
83872 sqlite3SelectDelete(db, pSelect);
84189 sqlite3SelectDup(db, pStep->pSelect, 0),
84204 Select *pSelect = sqlite3SelectDup(db, pStep->pSelect, 0);
84206 sqlite3Select(pParse, pSelect, &sDest);
84207 sqlite3SelectDelete(db, pSelect);
84627 if( !pTab->pSelect ){
84716 isView = pTab->pSelect!=0;
85171 Select *pSelect = 0; /* The SELECT statement */
85198 pSelect = sqlite3SelectNew(pParse, pEList, pSrc, pWhere, 0, 0, 0, 0, 0, 0);
85210 sqlite3Select(pParse, pSelect, &dest);
85229 sqlite3SelectDelete(db, pSelect);
86219 && !pParse->pNewTable->pSelect
86946 mask |= exprSelectTableUsage(pMaskSet, p->x.pSelect);
87624 pTerm->prereqRight = exprSelectTableUsage(pMaskSet, pExpr->x.pSelect);
90389 if( (pTab->tabFlags & TF_Ephemeral)!=0 || pTab->pSelect ) continue;
90563 if( (pTab->tabFlags & TF_Ephemeral)!=0 || pTab->pSelect ) continue;
93413 yygotominor.yy346.pExpr->x.pSelect = yymsp[-1].minor.yy3;
93427 yygotominor.yy346.pExpr->x.pSelect = yymsp[-1].minor.yy3;
93443 yygotominor.yy346.pExpr->x.pSelect = sqlite3SelectNew(pParse, 0,pSrc,0,0,0,0,0,0,0);
93458 p->x.pSelect = yymsp[-1].minor.yy3;
97201 if( !pTab || pTab->pSelect ){
104213 sqlite3_stmt *pSelect;
104215 rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pSelect, apVal);
104217 if( SQLITE_ROW==sqlite3_step(pSelect) ){
104220 const char *zText = (const char *)sqlite3_column_text(pSelect, i);
104223 sqlite3_reset(pSelect);
104228 rc = sqlite3_reset(pSelect);
104230 sqlite3_reset(pSelect);