Lines Matching defs:zDb
6006 ** in row iRow, column zColumn, table zTable in database zDb;
6010 ** SELECT zColumn FROM zDb.zTable WHERE [rowid] = iRow;
6060 const char *zDb,
7564 SQLITE_API int sqlite3_wal_checkpoint(sqlite3 *db, const char *zDb);
7569 ** Run a checkpoint operation on WAL database zDb attached to database
7620 ** If parameter zDb is NULL or points to a zero length string, then the
7631 ** If database zDb is the name of an attached database that is not in WAL
7633 ** zDb is not NULL (or a zero length string) and is not the name of any
7638 const char *zDb, /* Name of attached database (or NULL) */
11664 const char *zDb; /* Make sure all objects are contained in this database */
12099 SQLITE_PRIVATE void sqlite3CodeVerifyNamedSchema(Parse*, const char *zDb);
28569 char zDb[MAX_PATHNAME+1]; /* Database file path */
28570 int nDb; /* Number of valid bytes in zDb */
28596 memcpy(zDb, zPath, nDb);
28597 zDb[nDb] = '\0';
28599 if( 0==osStat(zDb, &sStat) ){
58112 ** Return a pointer corresponding to database zDb (i.e. "main", "temp")
58120 static Btree *findBtree(sqlite3 *pErrorDb, sqlite3 *pDb, const char *zDb){
58121 int i = sqlite3FindDbName(pDb, zDb);
58145 sqlite3Error(pErrorDb, SQLITE_ERROR, "unknown database %s", zDb);
65688 const char *zDb; /* database name - used by the update hook */
69429 const char *zDb; /* database name - used by the update hook */
69480 u.bi.zDb = db->aDb[u.bi.pC->iDb].zName;
69484 db->xUpdateCallback(db->pUpdateArg, u.bi.op, u.bi.zDb, u.bi.zTbl, u.bi.iKey);
69548 const char *zDb = db->aDb[u.bj.pC->iDb].zName;
69550 db->xUpdateCallback(db->pUpdateArg, SQLITE_DELETE, zDb, zTbl, u.bj.iKey);
71812 const char *zDb, /* The attached database containing the blob */
71878 pTab = sqlite3LocateTable(pParse, 0, zTable, zDb);
74044 ** Check to see if the zSpan given to this routine matches the zDb, zTab,
74045 ** and zCol. If any of zDb, zTab, and zCol are NULL then those fields will
74052 const char *zDb
74056 if( zDb && (sqlite3StrNICmp(zSpan, zDb, n)!=0 || zDb[n]!=0) ){
74088 ** The zDb variable is the name of the database (the "X"). This value may be
74091 ** value can be NULL if zDb is also NULL. If zTable is NULL it
74100 const char *zDb, /* Name of the database containing table, or NULL */
74126 /* Translate the schema name in zDb into a pointer to the corresponding
74130 if( zDb ){
74133 if( sqlite3StrICmp(db->aDb[i].zName,zDb)==0 ){
74157 if( sqlite3MatchSpanName(pEList->a[j].zSpan, zCol, zTab, zDb) ){
74167 if( zDb && pTab->pSchema!=pSchema ){
74209 if( zDb==0 && zTab!=0 && cnt==0 && pParse->pTriggerTab!=0 ){
74298 assert( zTab==0 && zDb==0 );
74336 if( zDb ){
74337 sqlite3ErrorMsg(pParse, "%s: %s.%s.%s", zErr, zDb, zTab, zCol);
74477 const char *zDb;
74483 zDb = 0;
74488 zDb = pExpr->pLeft->u.zToken;
74492 return lookupName(pParse, zDb, zTable, zColumn, pNC, pExpr);
79814 char *zDb; /* Name of database iDb */
79835 zDb = db->aDb[iDb].zName;
79845 if( sqlite3FindTable(db, zName, zDb) || sqlite3FindIndex(db, zName, zDb) ){
79870 if( sqlite3AuthCheck(pParse, SQLITE_ALTER_TABLE, zDb, pTab->zName, 0) ){
79926 "WHERE %s;", zDb, SCHEMA_TABLE(iDb), zTabName, zName, zWhere);
79950 zDb, SCHEMA_TABLE(iDb), zName, zName, zName,
79961 if( sqlite3FindTable(db, "sqlite_sequence", zDb) ){
79964 zDb, zName, pTab->zName);
80042 const char *zDb; /* Database name */
80056 zDb = db->aDb[iDb].zName;
80060 pTab = sqlite3FindTable(db, zTab, zDb);
80065 if( sqlite3AuthCheck(pParse, SQLITE_ALTER_TABLE, zDb, pTab->zName, 0) ){
80130 zDb, SCHEMA_TABLE(iDb), pNew->addColOffset, zCol, pNew->addColOffset+1,
81020 char *z, *zDb;
81059 zDb = db->aDb[iDb].zName;
81062 if( (pIdx = sqlite3FindIndex(db, z, zDb))!=0 ){
81064 }else if( (pTab = sqlite3LocateTable(pParse, 0, z, zDb))!=0 ){
81168 static int loadStat3(sqlite3 *db, const char *zDb){
81178 if( !sqlite3FindTable(db, "sqlite_stat3", zDb) ){
81184 " GROUP BY idx", zDb);
81200 pIdx = sqlite3FindIndex(db, zIndex, zDb);
81216 "SELECT idx,neq,nlt,ndlt,sample FROM %Q.sqlite_stat3", zDb);
81232 pIdx = sqlite3FindIndex(db, zIndex, zDb);
81805 pFix->zDb = db->aDb[iDb].zName;
81831 const char *zDb;
81835 zDb = pFix->zDb;
81837 if( pItem->zDatabase && sqlite3StrICmp(pItem->zDatabase, zDb) ){
82024 ** table zTab in database zDb. This function assumes that an authorization
82038 char *zDb = db->aDb[iDb].zName; /* Name of attached database */
82041 rc = db->xAuth(db->pAuthArg, SQLITE_READ, zTab,zCol,zDb,pParse->zAuthContext);
82044 sqlite3ErrorMsg(pParse, "access to %s.%s.%s is prohibited",zDb,zTab,zCol);
82518 const char *zDb;
82522 zDb = pParse->db->aDb[iDb].zName;
82524 zDb = p->zDatabase;
82526 return sqlite3LocateTable(pParse, isView, p->zName, zDb);
82541 SQLITE_PRIVATE Index *sqlite3FindIndex(sqlite3 *db, const char *zName, const char *zDb){
82546 assert( zDb!=0 || sqlite3BtreeHoldsAllMutexes(db) );
82551 if( zDb && sqlite3StrICmp(zDb, db->aDb[j].zName) ) continue;
83000 char *zDb = db->aDb[iDb].zName;
83001 if( sqlite3AuthCheck(pParse, SQLITE_INSERT, SCHEMA_TABLE(isTemp), 0, zDb) ){
83017 if( !isVirtual && sqlite3AuthCheck(pParse, code, zName, 0, zDb) ){
83031 char *zDb = db->aDb[iDb].zName;
83035 pTable = sqlite3FindTable(db, zName, zDb);
83045 if( sqlite3FindIndex(db, zName, zDb)!=0 ){
84342 const char *zDb = db->aDb[iDb].zName;
84344 if( sqlite3AuthCheck(pParse, SQLITE_DELETE, zTab, 0, zDb)){
84365 if( sqlite3AuthCheck(pParse, code, pTab->zName, zArg2, zDb) ){
84368 if( sqlite3AuthCheck(pParse, SQLITE_DELETE, pTab->zName, 0, zDb) ){
84812 const char *zDb = pDb->zName;
84813 if( sqlite3AuthCheck(pParse, SQLITE_INSERT, SCHEMA_TABLE(iDb), 0, zDb) ){
84818 if( sqlite3AuthCheck(pParse, i, zName, pTab->zName, zDb) ){
85197 const char *zDb = db->aDb[iDb].zName;
85199 if( sqlite3AuthCheck(pParse, SQLITE_DELETE, zTab, 0, zDb) ){
85203 if( sqlite3AuthCheck(pParse, code, pIndex->zName, pTab->zName, zDb) ){
85766 ** If argument zDb is NULL, then call sqlite3CodeVerifySchema() for each
85767 ** attached database. Otherwise, invoke it for the database named zDb only.
85769 SQLITE_PRIVATE void sqlite3CodeVerifyNamedSchema(Parse *pParse, const char *zDb){
85774 if( pDb->pBt && (!zDb || 0==sqlite3StrICmp(zDb, pDb->zName)) ){
85931 const char *zDb; /* Name of the database */
85964 zDb = db->aDb[iDb].zName;
85965 pTab = sqlite3FindTable(db, z, zDb);
85971 pIndex = sqlite3FindIndex(db, z, zDb);
86727 const char *zDb; /* Name of database holding pTab */
86786 zDb = db->aDb[iDb].zName;
86787 rcauth = sqlite3AuthCheck(pParse, SQLITE_DELETE, pTab->zName, 0, zDb);
89587 const char *zDb; /* Name of database containing pTab */
89597 zDb = db->aDb[iDb].zName;
89615 pTo = sqlite3FindTable(db, pFKey->zTo, zDb);
89617 pTo = sqlite3LocateTable(pParse, 0, pFKey->zTo, zDb);
90641 const char *zDb; /* Name of the database holding this table */
90694 zDb = pDb->zName;
90695 if( sqlite3AuthCheck(pParse, SQLITE_INSERT, pTab->zName, 0, zDb) ){
93690 const char *zDb = 0; /* The database name */
93725 zDb = pId2->n>0 ? pDb->zName : 0;
93726 if( sqlite3AuthCheck(pParse, SQLITE_PRAGMA, zLeft, zRight, zDb) ){
93739 rc = sqlite3_file_control(db, zDb, SQLITE_FCNTL_PRAGMA, (void*)aFcntl);
94152 if( sqlite3_file_control(db,zDb,SQLITE_FCNTL_MMAP_SIZE,&sz)==SQLITE_OK ){
94365 pTab = sqlite3FindTable(db, zRight, zDb);
94414 pIdx = sqlite3FindIndex(db, zRight, zDb);
94439 pTab = sqlite3FindTable(db, zRight, zDb);
94503 pTab = sqlite3FindTable(db, zRight, zDb);
94578 pTab = sqlite3LocateTable(pParse, 0, zRight, zDb);
94591 pParent = sqlite3LocateTable(pParse, 0, pFK->zTo, zDb);
94613 pParent = sqlite3LocateTable(pParse, 0, pFK->zTo, zDb);
95786 const char *zDb = db->aDb[i].zName;
95787 sqlite3Error(db, rc, "database schema is locked: %s", zDb);
101328 const char *zDb = db->aDb[iTabDb].zName;
101329 const char *zDbTrig = isTemp ? db->aDb[1].zName : zDb;
101334 if( sqlite3AuthCheck(pParse, SQLITE_INSERT, SCHEMA_TABLE(iTabDb),0,zDb)){
101601 const char *zDb;
101612 zDb = pName->a[0].zDatabase;
101615 assert( zDb!=0 || sqlite3BtreeHoldsAllMutexes(db) );
101618 if( zDb && sqlite3StrICmp(db->aDb[j].zName, zDb) ) continue;
101627 sqlite3CodeVerifyNamedSchema(pParse, zDb);
101665 const char *zDb = db->aDb[iDb].zName;
101668 if( sqlite3AuthCheck(pParse, code, pTrigger->zName, pTable->zName, zDb) ||
101669 sqlite3AuthCheck(pParse, SQLITE_DELETE, zTab, 0, zDb) ){
116425 const char *zDb, /* Database */
116430 sqlite3_wal_checkpoint(db, zDb);
116485 ** Checkpoint database zDb.
116489 const char *zDb, /* Name of attached database (or NULL) */
116512 if( zDb && zDb[0] ){
116513 iDb = sqlite3FindDbName(db, zDb);
116517 sqlite3Error(db, SQLITE_ERROR, "unknown database: %s", zDb);
116530 ** Checkpoint database zDb. If zDb is NULL, or if the buffer zDb points
116534 SQLITE_API int sqlite3_wal_checkpoint(sqlite3 *db, const char *zDb){
116535 return sqlite3_wal_checkpoint_v2(db, zDb, SQLITE_CHECKPOINT_PASSIVE, 0, 0);
119216 const char *zDb; /* logical database name */
119806 const char *zDb = p->zDb; /* Name of database (e.g. "main", "temp") */
119811 fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_content'", zDb, p->zName);
119813 fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segments'", zDb,p->zName);
119814 fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segdir'", zDb, p->zName);
119815 fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_docsize'", zDb, p->zName);
119816 fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_stat'", zDb, p->zName);
119876 p->zDb, p->zName
119913 p->zDb, p->zName, zContentCols
119921 p->zDb, p->zName
119933 p->zDb, p->zName
119938 p->zDb, p->zName
119961 zSql = sqlite3_mprintf("PRAGMA %Q.page_size", p->zDb);
120119 p->zDb,
120276 const char *zDb, /* Name of db (i.e. "main", "temp" etc.) */
120286 zSql = sqlite3_mprintf("SELECT * FROM %Q.%Q", zDb, zTbl);
120568 nDb + /* zDb */
120601 /* Fill in the zName and zDb fields of the vtab structure. */
120606 p->zDb = zCsr;
120645 p->zDb, p->zName);
122728 p->zDb, p->zName, zName
122735 p->zDb, p->zName, zName
122741 p->zDb, p->zName, zName
122746 p->zDb, p->zName, zName
122750 p->zDb, p->zName, zName
124713 char const *zDb; /* Name of database (e.g. "main") */
124715 int nDb; /* Result of strlen(zDb) */
124730 zDb = argv[1];
124731 nDb = (int)strlen(zDb);
124733 if( nDb==4 && 0==sqlite3_strnicmp("temp", zDb, 4) ){
124734 zDb = argv[3];
124735 nDb = (int)strlen(zDb);
124754 p->pFts3Tab->zDb = (char *)&p->pFts3Tab[1];
124755 p->pFts3Tab->zName = &p->pFts3Tab->zDb[nDb+1];
124759 memcpy((char *)p->pFts3Tab->zDb, zDb, nDb);
129015 zSql = sqlite3_mprintf(azSql[eStmt], p->zDb, p->zName, p->zWriteExprlist);
129019 zSql = sqlite3_mprintf(azSql[eStmt], p->zDb, p->zName);
129823 p->db, p->zDb, p->zSegmentsTbl, "block", iBlockid, 0, &p->pSegments
136477 char *zDb; /* Name of database containing r-tree table */
137127 pRtree->zDb, pRtree->zName,
137128 pRtree->zDb, pRtree->zName,
137129 pRtree->zDb, pRtree->zName
139230 , pRtree->zDb, pRtree->zName, zNewName
139231 , pRtree->zDb, pRtree->zName, zNewName
139232 , pRtree->zDb, pRtree->zName, zNewName
139270 const char *zDb,
139304 zDb, zPrefix, zDb, zPrefix, zDb, zPrefix, zDb, zPrefix, pRtree->iNodeSize
139327 char *zSql = sqlite3_mprintf(azSql[i], zDb, zPrefix);
139386 zSql = sqlite3_mprintf("PRAGMA %Q.page_size", pRtree->zDb);
139399 pRtree->zDb, pRtree->zName
139459 pRtree->zDb = (char *)&pRtree[1];
139460 pRtree->zName = &pRtree->zDb[nDb+1];
139464 memcpy(pRtree->zDb, argv[1], nDb);