Lines Matching refs:nKeyCol

17516   u16 nKeyCol;             /* Number of columns forming the key */  member
92225 int nKeyCol;
92231 nKeyCol = pOp->p4.i;
92233 rc = sqlite3VdbeSorterCompare(pC, pIn3, nKeyCol, &res);
95406 for(j=0; j<pIdx->nKeyCol; j++){
98427 int nKeyCol, /* Compare this many columns */
98443 r2->nField = nKeyCol;
98445 assert( r2->nField==nKeyCol );
98449 for(i=0; i<nKeyCol; i++){
104430 if( pIdx->nKeyCol>nExpr
110163 for(i=0; i<pPk->nKeyCol; i++){
110166 nField = pPk->nKeyCol;
110175 if( iPos<pPk->nKeyCol ) continue;
110196 sqlite3VdbeAddOp4Int(v, OP_IdxInsert, iCur, regRec, reg+1, pPk->nKeyCol);
110514 int nKeyCol; /* Number of index columns w/o the pk/rowid */
110634 int nKeyCol; /* Number of key columns */
110648 nKeyCol = sqlite3_value_int(argv[1]);
110649 assert( nKeyCol<=nCol );
110650 assert( nKeyCol>0 );
110674 p->nKeyCol = nKeyCol;
111084 sqlite3StrAccumInit(&sStat, 0, 0, 0, (p->nKeyCol+1)*100);
111087 for(i=0; i<p->nKeyCol; i++){
111278 nCol = pIdx->nKeyCol;
111284 nColTest = pIdx->uniqNotNull ? pIdx->nKeyCol-1 : nCol-1;
111344 sqlite3VdbeAddOp2(v, OP_Integer, pIdx->nKeyCol, regRowid);
111391 if( nColTest==1 && pIdx->nKeyCol==1 && IsUniqueIndex(pIdx) ){
111444 regKey = sqlite3GetTempRange(pParse, pPk->nKeyCol);
111445 for(j=0; j<pPk->nKeyCol; j++){
111451 sqlite3VdbeAddOp3(v, OP_MakeRecord, regKey, pPk->nKeyCol, regRowid);
111452 sqlite3ReleaseTempRange(pParse, regKey, pPk->nKeyCol);
111783 int nCol = pIndex->nKeyCol+1;
111867 if( !pIdx->aiRowEst || iCol>=pIdx->nKeyCol || pIdx->aiRowEst[iCol+1]==0 ){
111965 assert( !HasRowid(pIdx->pTable) || pIdx->nColumn==pIdx->nKeyCol+1 );
111967 nIdxCol = pIdx->nKeyCol;
114655 assert( pIdx->nKeyCol==1 && pIdx->onError!=OE_None );
114997 assert( pIdx->nKeyCol==1 );
115221 memcpy(zExtra, pIdx->aiRowLogEst, sizeof(LogEst)*(pIdx->nKeyCol+1));
115292 assert( iCol<MAX(pPk->nColumn,pPk->nKeyCol) );
115425 assert( pPk->nKeyCol==1 );
115435 for(i=j=1; i<pPk->nKeyCol; i++){
115445 pPk->nKeyCol = j;
115450 nPk = pPk->nColumn = pPk->nKeyCol;
115471 if( !isDupColumn(pIdx, pIdx->nKeyCol, pPk, i) ){
115472 testcase( hasColumn(pIdx->aiColumn, pIdx->nKeyCol, pPk->aiColumn[i]) );
115478 pIdx->nColumn = pIdx->nKeyCol;
115481 if( resizeIndexObject(db, pIdx, pIdx->nKeyCol+n) ) return;
115482 for(i=0, j=pIdx->nKeyCol; i<nPk; i++){
115483 if( !isDupColumn(pIdx, pIdx->nKeyCol, pPk, i) ){
115484 testcase( hasColumn(pIdx->aiColumn, pIdx->nKeyCol, pPk->aiColumn[i]) );
115494 assert( pIdx->nColumn>=pIdx->nKeyCol+n );
116790 sqlite3VdbeAddOp4(v, OP_SorterOpen, iSorter, 0, pIndex->nKeyCol, (char*)
116816 pIndex->nKeyCol); VdbeCoverage(v);
116881 p->nKeyCol = nCol - 1;
117146 nExtraCol = pPk ? pPk->nKeyCol : 1;
117163 pIndex->nKeyCol = pList->nExpr;
117193 for(i=0; i<pIndex->nKeyCol; i++, pListItem++){
117258 for(j=0; j<pPk->nKeyCol; j++){
117261 if( isDupColumn(pIndex, pIndex->nKeyCol, pPk, j) ){
117264 testcase( hasColumn(pIndex->aiColumn,pIndex->nKeyCol,x) );
117323 if( pIdx->nKeyCol!=pIndex->nKeyCol ) continue;
117324 for(k=0; k<pIdx->nKeyCol; k++){
117333 if( k==pIdx->nKeyCol ){
117535 int nCopy = MIN(ArraySize(aVal), pIdx->nKeyCol);
117562 for(i=nCopy+1; i<=pIdx->nKeyCol; i++){
117567 if( IsUniqueIndex(pIdx) ) a[pIdx->nKeyCol] = 0;
118332 for(j=0; j<pIdx->nKeyCol; j++){
118512 int nKey = pIdx->nKeyCol;
119394 if( pPk->nKeyCol==1 ){
119400 for(i=0; i<pPk->nKeyCol; i++){
119657 nPk = pPk->nKeyCol;
120072 pIdx->uniqNotNull ? pIdx->nKeyCol : pIdx->nColumn);
120138 nCol = (prefixOnly && pIdx->uniqNotNull) ? pIdx->nKeyCol : pIdx->nColumn;
122772 if( pIdx->nKeyCol==nCol && IsUniqueIndex(pIdx) && pIdx->pPartIdxWhere==0 ){
123114 assert( pIdx==0 || pIdx->nKeyCol==pFKey->nCol );
123173 for(i=0; i<pIdx->nKeyCol; i++){
123653 for(i=0; i<pIdx->nKeyCol; i++){
125707 nPkField = pPk->nKeyCol;
126269 regIdx, pIdx->nKeyCol); VdbeCoverage(v);
126288 for(i=0; i<pPk->nKeyCol; i++){
126304 int addrJump = sqlite3VdbeCurrentAddr(v)+pPk->nKeyCol;
126308 for(i=0; i<pPk->nKeyCol; i++){
126312 if( i==(pPk->nKeyCol-1) ){
126580 pIdx->uniqNotNull ? pIdx->nKeyCol: pIdx->nColumn);
126707 if( pDest->nKeyCol!=pSrc->nKeyCol || pDest->nColumn!=pSrc->nColumn ){
126713 for(i=0; i<pSrc->nKeyCol; i++){
130844 mx = pIdx->nKeyCol;
130858 i<pIdx->nKeyCol);
131372 for(kk=0; kk<pIdx->nKeyCol; kk++){
131383 pIdx->nKeyCol); VdbeCoverage(v);
134221 nKey = pPk->nKeyCol;
134890 assert( sqlite3PrimaryKeyIndex(pTab)->nKeyCol==nKey );
142639 for(i=0; i<pPk->nKeyCol; i++){
142676 dest.iSDParm2 = (pPk ? pPk->nKeyCol : -1);
142977 for(i=0; i<pIdx->nKeyCol; i++){
143077 nPk = pPk ? pPk->nKeyCol : 0;
143629 assert( pPk->nKeyCol==1 );
143682 assert( pPk->nKeyCol==1 );
143901 if( pTarget->nExpr!=pIdx->nKeyCol ) continue;
143909 nn = pIdx->nKeyCol;
144028 int nPk = pPk->nKeyCol;
145331 && sqlite3PrimaryKeyIndex(pNew)->nKeyCol!=1
148414 iRowidReg = sqlite3GetTempRange(pParse, pPk->nKeyCol);
148415 for(j=0; j<pPk->nKeyCol; j++){
148420 iRowidReg, pPk->nKeyCol); VdbeCoverage(v);
148590 sqlite3VdbeAddOp2(v, OP_OpenEphemeral, regRowset, pPk->nKeyCol);
148685 int nPk = pPk->nKeyCol;
149966 for(i=0; i<pIdx->nKeyCol; i++){
151234 for(i=0; i<pIdx->nKeyCol; i++){
151240 if( i==pIdx->nKeyCol ){
151392 int nKeyCol; /* Number of columns in the constructed index */
151424 nKeyCol = 0;
151456 if( whereLoopResize(pParse->db, pLoop, nKeyCol+1) ){
151459 pLoop->aLTerm[nKeyCol++] = pTerm;
151464 assert( nKeyCol>0 || pParse->db->mallocFailed );
151465 pLoop->u.btree.nEq = pLoop->nLTerm = nKeyCol;
151482 if( extraCols & MASKBIT(i) ) nKeyCol++;
151485 nKeyCol += pTable->nCol - BMS + 1;
151489 pIdx = sqlite3AllocateIndexObject(pParse->db, nKeyCol+1, 0, &zNotUsed);
151534 assert( n==nKeyCol );
151541 sqlite3VdbeAddOp2(v, OP_OpenAutoindex, pLevel->iIdxCur, nKeyCol+1);
153172 assert( pNew->u.btree.nEq<pProbe->nKeyCol
153216 if( IsUniqueIndex(pProbe) && saved_nEq==pProbe->nKeyCol-1 ){
153306 || (iCol>=0 && nInMul==0 && saved_nEq==pProbe->nKeyCol-1)
153309 || (pProbe->nKeyCol==1 && pProbe->onError && eOp==WO_EQ)
153460 && (pNew->u.btree.nEq<pProbe->nKeyCol ||
153491 && saved_nEq+1<pProbe->nKeyCol
153545 for(jj=0; jj<pIndex->nKeyCol; jj++){
153549 for(jj=0; jj<pIndex->nKeyCol; jj++){
153667 sPk.nKeyCol = 1;
154445 u16 nKeyCol; /* Number of key columns in pIndex */
154556 nKeyCol = 0;
154561 nKeyCol = pIndex->nKeyCol;
154563 assert( nColumn==nKeyCol+1 || !HasRowid(pIndex->pTable) );
154710 if( j==0 || j<nKeyCol ){
155282 || pIdx->nKeyCol>ArraySize(pLoop->aLTermSpace)
155285 for(j=0; j<pIdx->nKeyCol; j++){
155292 if( j!=pIdx->nKeyCol ) continue;