Lines Matching refs:nOrderBy
5802 int nOrderBy; /* Number of terms in the ORDER BY clause */ member
108348 int nOrderBy = p->pOrderBy->nExpr;
108350 KeyInfo *pRet = sqlite3KeyInfoAlloc(db, nOrderBy+nExtra, 1);
108353 for(i=0; i<nOrderBy; i++){
109272 int nOrderBy; /* Number of terms in the ORDER BY clause */
109295 nOrderBy = pOrderBy->nExpr;
109304 for(j=0, pItem=pOrderBy->a; j<nOrderBy; j++, pItem++){
109308 if( j==nOrderBy ){
109314 if( pOrderBy ) pOrderBy->a[nOrderBy++].u.x.iOrderByCol = (u16)i;
109326 aPermute = sqlite3DbMallocRaw(db, sizeof(int)*nOrderBy);
109329 for(i=0, pItem=pOrderBy->a; i<nOrderBy; i++, pItem++){
109354 assert( nOrderBy>=nExpr || db->mallocFailed );
109515 sqlite3VdbeAddOp4(v, OP_Compare, destA.iSdst, destB.iSdst, nOrderBy,
117812 for(i=0; i<p->nOrderBy; i++){
118063 int nOrderBy;
118083 nOrderBy = 0;
118091 nOrderBy = n;
118099 + sizeof(*pIdxOrderBy)*nOrderBy );
118112 pUsage = (struct sqlite3_index_constraint_usage*)&pIdxOrderBy[nOrderBy];
118114 *(int*)&pIdxInfo->nOrderBy = nOrderBy;
118146 for(i=0; i<nOrderBy; i++){
121583 pIdxInfo->nOrderBy : 0);
121799 u16 nOrderBy; /* Number terms in the ORDER BY clause */
121840 nOrderBy = pOrderBy->nExpr;
121841 testcase( nOrderBy==BMS-1 );
121842 if( nOrderBy>BMS-1 ) return 0; /* Cannot optimize overly large ORDER BYs */
121844 obDone = MASKBIT(nOrderBy)-1;
121861 for(i=0; i<nOrderBy; i++){
121945 for(i=0; bOnce && i<nOrderBy; i++){
121997 for(i=0; i<nOrderBy; i++){
122010 if( obSat==obDone ) return (i8)nOrderBy;
122012 for(i=nOrderBy-1; i>0; i--){
122071 int nOrderBy,
122088 assert( nOrderBy>0 && 66==sqlite3LogEst(100) );
122089 rScale = sqlite3LogEst((nOrderBy-nSorted)*100/nOrderBy) - 66;
122122 int nOrderBy; /* Number of ORDER BY clause terms */
122152 nOrderBy = 0;
122154 nOrderBy = pWInfo->pOrderBy->nExpr;
122159 nSpace += sizeof(LogEst) * nOrderBy;
122169 if( nOrderBy ){
122177 memset(aSortCost, 0, sizeof(LogEst) * nOrderBy);
122179 assert( aSortCost==0 || &pSpace[nSpace]==(char*)&aSortCost[nOrderBy] );
122190 if( nOrderBy ){
122197 aFrom[0].isOrdered = nLoop>0 ? -1 : nOrderBy;
122229 if( isOrdered>=0 && isOrdered<nOrderBy ){
122232 pWInfo, nRowEst, nOrderBy, isOrdered
122239 aSortCost[isOrdered], (nOrderBy-isOrdered), nOrderBy,
134624 if( pInfo->nOrderBy==1 ){
139051 if( pInfo->nOrderBy==1
155405 if( ( pIdxInfo->nOrderBy==1
155409 ( pIdxInfo->nOrderBy==2