Lines Matching refs:nKey
16279 sqlite3_int64 nKey; /* Size of pKey for indexes. PRIMARY KEY for tabs */ member
69634 i64 nKey; /* The key for INTKEY tables, or nPayload otherwise */
69695 i64 nKey; /* Size of pKey, or last integer key */
70739 if( p->pgnoRoot==pgnoRoot && (isClearTable || p->info.nKey==iRow) ){
70857 pCur->nKey = sqlite3BtreeIntegerKey(pCur);
70866 pCur->nKey = sqlite3BtreePayloadSize(pCur);
70867 pKey = sqlite3Malloc( pCur->nKey + 9 + 8 );
70869 rc = sqlite3BtreePayload(pCur, 0, (int)pCur->nKey, pKey);
70871 memset(((u8*)pKey)+pCur->nKey, 0, 9+8);
70998 i64 nKey, /* Integer key for tables. Size of pKey for indices */
71007 assert( nKey==(i64)(int)nKey );
71010 sqlite3VdbeRecordUnpack(pKeyInfo, (int)nKey, pKey, pIdxKey);
71019 rc = sqlite3BtreeTableMoveto(pCur, nKey, bias, pRes);
71043 rc = btreeMoveto(pCur, pCur->pKey, pCur->nKey, 0, &skipNext);
71387 pInfo->nSize = 4 + getVarint(&pCell[4], (u64*)&pInfo->nKey);
71463 pInfo->nKey = *(i64*)&iKey;
71500 pInfo->nKey = nPayload;
74945 if( a->nKey!=b->nKey ) return 0;
74996 return pCur->info.nKey;
75845 if( pCur->info.nKey==intKey ){
75849 if( pCur->info.nKey<intKey ){
75858 if( pCur->info.nKey+1==intKey ){
75863 if( pCur->info.nKey==intKey ){
75936 pCur->info.nKey = nCellKey;
76194 nCell = (int)pCur->info.nKey;
77126 nHeader += putVarint(&pCell[nHeader], *(u64*)&pX->nKey);
77128 assert( pX->nKey<=0x7fffffff && pX->pKey!=0 );
77129 nSrc = nPayload = (int)pX->nKey;
77183 assert( info.nKey==pX->nKey );
78857 sz = 4 + putVarint(&pCell[4], info.nKey);
79480 invalidateIncrblobCursors(p, pCur->pgnoRoot, pX->nKey, 0);
79489 assert( pX->nKey==pCur->info.nKey );
79498 if( (pCur->curFlags&BTCF_ValidNKey)!=0 && pX->nKey==pCur->info.nKey ){
79514 rc = sqlite3BtreeTableMoveto(pCur, pX->nKey,
79541 rc = btreeMoveto(pCur, pX->pKey, pX->nKey,
79553 if( pCur->info.nKey==pX->nKey ){
79556 x2.nData = pX->nKey;
79566 assert( pPage->intKey || pX->nKey>=0 || (flags & BTREE_PREFORMAT) );
79579 pCur->pgnoRoot, pX->nKey, pX->nData, pPage->pgno,
79693 pCur->pKey = sqlite3Malloc( pX->nKey );
79697 memcpy(pCur->pKey, pX->pKey, pX->nKey);
79701 pCur->nKey = pX->nKey;
79937 invalidateIncrblobCursors(p, pCur->pgnoRoot, pCur->info.nKey, 0);
80980 if( keyCanBeEqual ? (info.nKey > maxKey) : (info.nKey >= maxKey) ){
80981 checkAppendMsg(pCheck, "Rowid %lld out of order", info.nKey);
80983 maxKey = info.nKey;
88561 int nKey, /* Size of the binary record */
88577 while( idx<szHdr && d<=(u32)nKey ){
88591 if( d>(u32)nKey && u ){
88736 int nKey, const void *pKey, /* The record to verify */
88747 assert( nKey>=0 );
88748 assert( szHdr<=(u32)nKey );
92013 int nKey,
92021 sqlite3VdbeRecordUnpack(pKeyInfo, nKey, pKey, pRet);
98280 x.nKey = pKey->u.i;
98296 sqlite3VdbePreUpdateHook(p,pC,SQLITE_INSERT,zDb,pTab,x.nKey,pOp->p2,-1);
98309 if( pOp->p5 & OPFLAG_LASTROWID ) db->lastRowid = x.nKey;
98337 zDb, pTab->zName, x.nKey);
99056 x.nKey = pIn2->n;
102615 int nKey; /* Number of bytes in key */
102968 pReadr->nKey = (int)nRec;
103905 pReadr1->aKey, pReadr1->nKey, pReadr2->aKey, pReadr2->nKey
104156 int nKey = pReader->nKey;
104162 if( (iEof + nKey + sqlite3VarintLen(nKey))>(iStart + pIncr->mxSz) ) break;
104165 vdbePmaWriteVarint(&writer, nKey);
104166 vdbePmaWriteBlob(&writer, pReader->aKey, nKey);
104326 pTask, &bCached, p1->aKey, p1->nKey, p2->aKey, p2->nKey
104948 *pnKey = pReader->nKey;
104962 void *pKey; int nKey; /* Sorter key to copy into pOut */
104966 pKey = vdbeSorterRowkey(pSorter, &nKey);
104967 if( sqlite3VdbeMemClearAndResize(pOut, nKey) ){
104970 pOut->n = nKey;
104972 memcpy(pOut->z, pKey, nKey);
105003 void *pKey; int nKey; /* Sorter key to compare pVal with */
105016 pKey = vdbeSorterRowkey(pSorter, &nKey);
105017 sqlite3VdbeRecordUnpack(pKeyInfo, nKey, pKey, r2);
122881 static int isDupColumn(Index *pIdx, int nKey, Index *pPk, int iCol){
122883 assert( nKey<=pIdx->nColumn );
122891 for(i=0; i<nKey; i++){
126169 int nKey = pIdx->nKeyCol;
126173 pKey = sqlite3KeyInfoAlloc(pParse->db, nKey, nCol-nKey);
127181 i16 nKey; /* Number of memory cells in the row key */
127423 nKey = nPk; /* OP_Found will use an unpacked key */
127439 nKey = 0; /* Zero tells OP_Found to use a composite key */
127445 nKey = 1; /* OP_DeferredSeek always uses a single rowid */
127475 assert( nKey==nPk ); /* OP_Found will use an unpacked key */
127478 sqlite3VdbeAddOp4Int(v, OP_NotFound, iDataCur, addrBypass, iKey, nKey);
127488 assert( nKey==0 ); /* OP_Found will use a composite key */
127492 assert( nKey==1 );
127515 iKey, nKey, count, OE_Default, eOnePass, aiCurOnePass[1]);
141848 int nKey; /* Number of PK columns for table pTab (>=1) */
142543 int nKey; /* Number of sorting key columns, including OP_Sequence */
142549 nKey = nExpr - pSort->nOBSat + bSeq;
142559 pOp->p2 = nKey + nData;
142847 int nKey = 1;
142852 nKey = pPk->nKeyCol;
142854 for(k=0; k<nKey; k++){
142866 pSort->aDefer[nDefer].nKey = nKey;
143226 int nKey;
143232 nKey = pSO->nExpr;
143234 r2 = sqlite3GetTempRange(pParse, nKey+2);
143235 r3 = r2+nKey+1;
143249 for(i=0; i<nKey; i++){
143254 sqlite3VdbeAddOp2(v, OP_Sequence, iParm, r2+nKey);
143255 sqlite3VdbeAddOp3(v, OP_MakeRecord, r2, nKey+2, r1);
143256 sqlite3VdbeAddOp4Int(v, OP_IdxInsert, iParm, r1, r2, nKey+2);
143259 sqlite3ReleaseTempRange(pParse, r2, nKey+2);
143450 int nKey; /* Number of key columns in sorter record */
143480 nRefKey = MAX(nRefKey, pSort->aDefer[i].nKey);
143500 nKey = pOrderBy->nExpr - pSort->nOBSat;
143508 nKey+1+nColumn+nRefKey);
143524 for(i=0, iCol=nKey+bSeq-1; i<nColumn; i++){
143538 int nKey = pSort->aDefer[i].nKey;
143548 assert( sqlite3PrimaryKeyIndex(pTab)->nKeyCol==nKey );
143549 for(k=0; k<nKey; k++){
143553 sqlite3VdbeAddOp4Int(v, OP_SeekGE, iCsr, iJmp+2, regKey, nKey);
143554 sqlite3VdbeAddOp4Int(v, OP_IdxLE, iCsr, iJmp+3, regKey, nKey);
143582 sqlite3VdbeAddOp3(v, OP_Column, iSortTab, nKey+bSeq, regRow);
148491 int nKey; /* Key columns to be skipped */
148500 nKey = 0;
148505 nKey = pF->pFExpr->pLeft->x.pList->nExpr;
148506 if( ALWAYS(!pF->bOBUnique) ) nKey++;
148510 sqlite3VdbeAddOp3(v, OP_Column, pF->iOBTab, nKey+j, regAgg+j);
148514 int iBaseCol = nKey + nArg + (pF->bOBPayload==0 && pF->bOBUnique==0);
152387 int nKey = 0; /* Number of elements in regKey for WITHOUT ROWID */
152766 nKey = nPk;
152852 nKey = nPk;
152897 sqlite3VdbeAddOp4Int(v, OP_NotFound, iDataCur, labelBreak, regKey,nKey);
153051 sqlite3VdbeAddOp4Int(v, OP_NotFound,iDataCur,labelContinue,regKey,nKey);
153096 sqlite3VdbeAddOp4Int(v, OP_NotFound,iDataCur,labelContinue,regKey,nKey);
184147 void *pKey; int nKey; /* Key associated with this element */
184169 SQLITE_PRIVATE void *sqlite3Fts3HashInsert(Fts3Hash*, const void *pKey, int nKey, void *pData);
184170 SQLITE_PRIVATE void *sqlite3Fts3HashFind(const Fts3Hash*, const void *pKey, int nKey);
184199 #define fts3HashKeysize(E) ((E)->nKey)
185780 int nKey;
185793 else if( isFts4 && fts3IsSpecialColumn(z, &nKey, &zVal) ){
185814 if( nKey==pOp->nOpt && !sqlite3_strnicmp(z, pOp->zOpt, pOp->nOpt) ){
191726 int nKey = pKey->n;
191731 assert( nKey==4 );
191733 nKey += 1+sqlite3Fts3ReadInt(&zInput[nKey+1], &nNear);
191741 cNext = zInput[nKey];
191752 *pnConsumed = (int)((zInput - z) + nKey);
192677 static int fts3StrHash(const void *pKey, int nKey){
192680 if( nKey<=0 ) nKey = (int) strlen(z);
192681 while( nKey > 0 ){
192683 nKey--;
192695 static int fts3BinHash(const void *pKey, int nKey){
192698 while( nKey-- > 0 ){
192789 int h = (*xHash)(elem->pKey, elem->nKey) & (new_size-1);
192803 int nKey,
192816 if( (*xCompare)(elem->pKey,elem->nKey,pKey,nKey)==0 ){
192865 int nKey
192873 h = (*xHash)(pKey,nKey);
192875 return fts3FindElementByHash(pH,pKey,nKey, h & (pH->htsize-1));
192883 SQLITE_PRIVATE void *sqlite3Fts3HashFind(const Fts3Hash *pH, const void *pKey, int nKey){
192886 pElem = sqlite3Fts3HashFindElem(pH, pKey, nKey);
192908 int nKey, /* Number of bytes in the key */
192920 hraw = (*xHash)(pKey, nKey);
192923 elem = fts3FindElementByHash(pH,pKey,nKey,h);
192944 new_elem->pKey = fts3HashMalloc( nKey );
192949 memcpy((void*)new_elem->pKey, pKey, nKey);
192953 new_elem->nKey = nKey;
196577 int nKey = fts3HashKeysize(pE);
196578 if( nTerm==0 || (nKey>=nTerm && 0==memcmp(zKey, zTerm, nTerm)) ){
199116 int nKey, /* Number of bytes in nKey */
199170 if( fts3TermCmp(zKey, nKey, reader.term.a, reader.term.n)<=0 ){
199897 int nKey = pCsr->nTerm;
199898 rc = fts3IncrmergeLoad(p, iAbsLevel, iIdx-1, zKey, nKey, pWriter);
205910 u32 i, j, k, nKey, sz, n, iEnd, rc;
205941 nKey = i-1;
205947 testcase( nKey==0 );
205948 rawKey = memchr(zKey, '\\', nKey)==0;
205952 nKey = i;
205953 if( nKey==0 ){
205972 if( jsonLabelCompare(zKey, nKey, rawKey, zLabel, sz, rawLabel) ){
205997 jsonBlobAppendNode(&ix, rawKey?JSONB_TEXTRAW:JSONB_TEXT5, nKey, 0);
206001 && jsonBlobMakeEditable(pParse, ix.nBlob+nKey+v.nBlob)
206004 nIns = ix.nBlob + nKey + v.nBlob;
206011 memcpy(&pParse->aBlob[k], zKey, nKey);
206012 k += nKey;
238071 int nKey; /* Length of key in bytes */
238182 iHash = fts5HashKey(nNew, (u8*)fts5EntryKey(p), p->nKey);
238266 && p->nKey==nToken+1
238296 p->nKey = nToken+1;
238417 int nMin = MIN(p1->nKey, p2->nKey);
238421 cmp = p1->nKey - p2->nKey;
238467 || (pIter->nKey>=nTerm && 0==memcmp(fts5EntryKey(pIter), pTerm, nTerm))
238506 if( nTerm==p->nKey && memcmp(zKey, pTerm, nTerm)==0 ) break;
238578 int nTerm = p->nKey;