• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /asuswrt-rt-n18u-9.0.0.4.380.2695/release/src-rt-6.x.4708/router/sqlite/

Lines Matching refs:pParent

11723 ** Frames are stored in a linked list headed at Vdbe.pParent. Vdbe.pParent
11742 VdbeFrame *pParent; /* Parent of this frame */
43809 ** The pParent field points back to the parent page. This allows us to
48615 ** Page pParent is an internal (non-leaf) tree page. This function
48617 ** cell in page pParent. Or, if iIdx is equal to the total number of
48618 ** cells in pParent, that page number iChild is the right-child of
48621 static void assertParentIndex(MemPage *pParent, int iIdx, Pgno iChild){
48622 assert( iIdx<=pParent->nCell );
48623 if( iIdx==pParent->nCell ){
48624 assert( get4byte(&pParent->aData[pParent->hdrOffset+8])==iChild );
48626 assert( get4byte(findCell(pParent, iIdx))==iChild );
50084 ** pParent is its parent. pPage must have a single overflow entry
50088 ** cell that will be inserted into pParent. Such a cell consists of a 4
50093 static int balance_quick(MemPage *pParent, MemPage *pPage, u8 *pSpace){
50100 assert( sqlite3PagerIswriteable(pParent->pDbPage) );
50134 ptrmapPut(pBt, pgnoNew, PTRMAP_BTREE, pParent->pgno, &rc);
50140 /* Create a divider cell to insert into pParent. The divider cell
50159 /* Insert the new divider cell into pParent. */
50160 insertCell(pParent, pParent->nCell, pSpace, (int)(pOut-pSpace),
50163 /* Set the right-child pointer of pParent to point to the new page. */
50164 put4byte(&pParent->aData[pParent->hdrOffset+8], pgnoNew);
50275 ** This routine redistributes cells on the iParentIdx'th child of pParent
50293 ** inserted into or removed from the parent page (pParent). Doing so
50304 ** page (pParent) the parent page becomes overfull, this buffer is
50315 MemPage *pParent, /* Parent page of siblings being balanced */
50316 int iParentIdx, /* Index of "the page" in pParent */
50318 int isRoot /* True if pParent is a root-page */
50326 int nxDiv; /* Next divider slot in pParent->aCell[] */
50340 u8 *apDiv[NB-1]; /* Divider cells in pParent */
50348 pBt = pParent->pBt;
50350 assert( sqlite3PagerIswriteable(pParent->pDbPage) );
50353 TRACE(("BALANCE: begin page %d child of %d\n", pPage->pgno, pParent->pgno));
50356 /* At this point pParent may have at most one overflow cell. And if
50361 assert( pParent->nOverflow==0 || pParent->nOverflow==1 );
50362 assert( pParent->nOverflow==0 || pParent->aOvfl[0].idx==iParentIdx );
50368 /* Find the sibling pages to balance. Also locate the cells in pParent
50371 ** if there are fewer than NN siblings on the other side. If pParent
50372 ** has NB or fewer children then all children of pParent are taken.
50379 i = pParent->nOverflow + pParent->nCell;
50394 if( (i+nxDiv-pParent->nOverflow)==pParent->nCell ){
50395 pRight = &pParent->aData[pParent->hdrOffset+8];
50397 pRight = findCell(pParent, i+nxDiv-pParent->nOverflow);
50409 if( i+nxDiv==pParent->aOvfl[0].idx && pParent->nOverflow ){
50410 apDiv[i] = pParent->aOvfl[0].pCell;
50412 szNew[i] = cellSizePtr(pParent, apDiv[i]);
50413 pParent->nOverflow = 0;
50415 apDiv[i] = findCell(pParent, i+nxDiv-pParent->nOverflow);
50417 szNew[i] = cellSizePtr(pParent, apDiv[i]);
50432 int iOff = SQLITE_PTR_TO_INT(apDiv[i]) - SQLITE_PTR_TO_INT(pParent->aData);
50439 apDiv[i] = &aOvflSpace[apDiv[i]-pParent->aData];
50442 dropCell(pParent, i+nxDiv-pParent->nOverflow, szNew[i], &rc);
50472 ** from pParent.
50482 ** leafData: 1 if pPage holds key+data and pParent holds only keys.
50603 assert( cntNew[0]>0 || (pParent->pgno==1 && pParent->nCell==0) );
50636 ptrmapPut(pBt, pNew->pgno, PTRMAP_BTREE, pParent->pgno, &rc);
50693 assert( sqlite3PagerIswriteable(pParent->pDbPage) );
50698 ** Insert divider cells into pParent as necessary.
50754 sz = cellSizePtr(pParent, pCell);
50760 insertCell(pParent, nxDiv, pCell, sz, pTemp, pNew->pgno, &rc);
50762 assert( sqlite3PagerIswriteable(pParent->pDbPage) );
50776 if( isRoot && pParent->nCell==0 && pParent->hdrOffset<=apNew[0]->nFree ){
50795 copyNodeContent(apNew[0], pParent, &rc);
50898 ptrmapCheckPages(&pParent, 1);
50902 assert( pParent->isInit );
51029 MemPage * const pParent = pCur->apPage[iPage-1];
51032 rc = sqlite3PagerWrite(pParent->pDbPage);
51038 && pParent->pgno!=1
51039 && pParent->nCell==iIdx
51043 ** into pParent, which may cause pParent overflow. If this
51044 ** happens, the next interation of the do-loop will balance pParent
51055 rc = balance_quick(pParent, pPage, aBalanceQuickSpace);
51061 ** modifying the contents of pParent, which may cause pParent to
51077 rc = balance_nonroot(pParent, iIdx, pSpace, iPage==1);
55922 for(pFrame=p->pFrame; pFrame->pParent; pFrame=pFrame->pParent);
60297 p->pFrame = pFrame->pParent;
63220 for(u.be.pFrame=p->pFrame; u.be.pFrame->pParent; u.be.pFrame=u.be.pFrame->pParent);
64430 for(u.by.pFrame=p->pFrame; u.by.pFrame && u.by.pFrame->token!=u.by.t; u.by.pFrame=u.by.pFrame->pParent);
64487 u.by.pFrame->pParent = p->pFrame;
64583 for(u.ca.pFrame=p->pFrame; u.ca.pFrame->pParent; u.ca.pFrame=u.ca.pFrame->pParent);
80250 ** Given that pParent is the parent table for foreign key constraint pFKey,
80289 Table *pParent, /* Parent table of FK constraint pFKey */
80305 ** maps to the INTEGER PRIMARY KEY of table pParent. If so, leave *ppIdx
80316 ** mapped to the primary key of table pParent, or
80320 if( pParent->iPKey>=0 ){
80322 if( !sqlite3StrICmp(pParent->aCol[pParent->iPKey].zName, zKey) ) return 0;
80331 for(pIdx=pParent->pIndex; pIdx; pIdx=pIdx->pNext){
80339 ** the PRIMARY KEY of table pParent. The PRIMARY KEY index may be
80350 ** map to an explicit list of columns in table pParent. Check if this
80362 zDfltColl = pParent->aCol[iCol].zColl;
80368 zIdxCol = pParent->aCol[iCol].zName;
89221 Select *pParent;
89453 for(pParent=p; pParent; pParent=pParent->pPrior, pSub=pSub->pPrior){
89458 pSrc = pParent->pSrc; /* FROM clause of the outer query */
89461 assert( pParent==p ); /* First time through the loop */
89464 assert( pParent!=p ); /* 2nd and subsequent times through the loop */
89465 pSrc = pParent->pSrc = sqlite3SrcListAppend(db, 0, 0, 0);
89488 pParent->pSrc = pSrc = sqlite3SrcListEnlarge(db, pSrc, nSubSrc-1,iFrom+1);
89516 pList = pParent->pEList;
89525 substExprList(db, pParent->pEList, iParent, pSub->pEList);
89527 substExprList(db, pParent->pGroupBy, iParent, pSub->pEList);
89528 pParent->pHaving = substExpr(db, pParent->pHaving, iParent, pSub->pEList);
89531 assert( pParent->pOrderBy==0 );
89532 pParent->pOrderBy = pSub->pOrderBy;
89534 }else if( pParent->pOrderBy ){
89535 substExprList(db, pParent->pOrderBy, iParent, pSub->pEList);
89543 assert( pParent->pHaving==0 );
89544 pParent->pHaving = pParent->pWhere;
89545 pParent->pWhere = pWhere;
89546 pParent->pHaving = substExpr(db, pParent->pHaving, iParent, pSub->pEList);
89547 pParent->pHaving = sqlite3ExprAnd(db, pParent->pHaving,
89549 assert( pParent->pGroupBy==0 );
89550 pParent->pGroupBy = sqlite3ExprListDup(db, pSub->pGroupBy, 0);
89552 pParent->pWhere = substExpr(db, pParent->pWhere, iParent, pSub->pEList);
89553 pParent->pWhere = sqlite3ExprAnd(db, pParent->pWhere, pWhere);
89559 pParent->selFlags |= pSub->selFlags & SF_Distinct;
89568 pParent->pLimit = pSub->pLimit;
106974 Fts3Expr *pParent; /* pParent->pLeft==this or pParent->pRight==this */
108817 isReqPos || (pExpr->pParent && pExpr->pParent->eType==FTSQUERY_NEAR),
108838 if( pExpr->pParent && pExpr->pParent->eType==FTSQUERY_NEAR ){
110027 while( pSplit->pParent && opPrecedence(pSplit->pParent)<=opPrecedence(pNew) ){
110028 pSplit = pSplit->pParent;
110031 if( pSplit->pParent ){
110032 assert( pSplit->pParent->pRight==pSplit );
110033 pSplit->pParent->pRight = pNew;
110034 pNew->pParent = pSplit->pParent;
110039 pSplit->pParent = pNew;
110145 p->pParent = pPrev;
112315 SegmentNode *pParent; /* Parent node (or NULL for root node) */
113608 SegmentNode *pParent = pTree->pParent;
113609 rc = fts3NodeAddTerm(p, &pParent, isCopyTerm, zTerm, nTerm);
113610 if( pTree->pParent==0 ){
113611 pTree->pParent = pParent;
113615 pNew->pParent = pParent;
113669 if( !pTree->pParent ){
113690 p, pTree->pParent, iHeight+1, iFree, iNextFree, piLast, paRoot, pnRoot
113704 fts3NodeFree(p->pParent);
114962 Fts3Expr *pParent = pExpr->pParent;
114966 && pParent
114967 && pParent->eType==FTSQUERY_NEAR
114968 && pParent->pRight==pExpr
114973 int nNear = pParent->nNear;
114974 Fts3Expr *pLeft = pParent->pLeft;
114985 pParent = pExpr->pParent;
116199 RtreeNode *pParent; /* Parent node */
116358 static RtreeNode *nodeNew(Rtree *pRtree, RtreeNode *pParent, int zero){
116365 pNode->pParent = pParent;
116367 nodeReference(pParent);
116379 RtreeNode *pParent, /* Either the parent node or NULL */
116389 assert( !pParent || !pNode->pParent || pNode->pParent==pParent );
116390 if( pParent && !pNode->pParent ){
116391 nodeReference(pParent);
116392 pNode->pParent = pParent;
116404 pNode->pParent = pParent;
116417 nodeReference(pParent);
116534 if( pNode->pParent ){
116535 rc = nodeRelease(pRtree, pNode->pParent);
116874 RtreeNode *pParent = pNode->pParent;
116875 if( pParent ){
116876 return nodeRowidIndex(pRtree, pParent, pNode->iNode);
116908 pCsr->pNode = pNode->pParent;
117398 while( p->pParent ){
117400 RtreeNode *pParent = p->pParent;
117403 nodeGetCell(pRtree, pParent, iCell, &cell);
117406 nodeOverwriteCell(pRtree, pParent, &cell, iCell);
117409 p = pParent;
117893 nodeRelease(pRtree, pChild->pParent);
117895 pChild->pParent = pNode;
117946 pRight = nodeNew(pRtree, pLeft->pParent, 1);
117974 rc = rtreeInsertCell(pRtree, pLeft->pParent, &leftbbox, iHeight+1);
117979 RtreeNode *pParent = pLeft->pParent;
117981 nodeOverwriteCell(pRtree, pParent, &leftbbox, iCell);
117982 AdjustTree(pRtree, pParent, &leftbbox);
117984 if( (rc = rtreeInsertCell(pRtree, pRight->pParent, &rightbbox, iHeight+1)) ){
118028 if( pLeaf->iNode!=1 && pLeaf->pParent==0 ){
118032 rc = nodeAcquire(pRtree, iNode, 0, &pLeaf->pParent);
118038 rc = fixLeafParent(pRtree, pLeaf->pParent);
118048 RtreeNode *pParent;
118055 pParent = pNode->pParent;
118056 pNode->pParent = 0;
118057 if( SQLITE_OK!=(rc = deleteCell(pRtree, pParent, iCell, iHeight+1))
118058 || SQLITE_OK!=(rc = nodeRelease(pRtree, pParent))
118090 RtreeNode *pParent = pNode->pParent;
118091 if( pParent ){
118103 nodeOverwriteCell(pRtree, pParent, &box, ii);
118104 fixBoundingBox(pRtree, pParent);
118130 RtreeNode *pParent = pNode->pParent;
118131 if( (pParent->iNode!=1 || NCELL(pParent)!=1)
118256 nodeRelease(pRtree, pChild->pParent);
118258 pChild->pParent = pNode;