/ Check-in [9325c1a8]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix requirements marks associate with STAT3.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 9325c1a8c413dfbf0381190d8347f0a446ae5f5b
User & Date: drh 2011-10-11 12:39:19
Context
2011-10-11
17:54
Remove all precision and width limits from formatting fields in the sqlite3_mprintf() family of functions. Malloc for space as necessary. The prevents a stack overflow on very large numbers using %f. check-in: 1f843fb3 user: drh tags: trunk
14:19
Merge the latest trunk changes into the apple-osx branch. check-in: 7e2c4898 user: drh tags: apple-osx
12:58
Merge all the latest trunk changes into the sessions branch - especially the SQLITE_ENABLE_STAT3 enhancements. check-in: 403431ca user: drh tags: sessions
12:39
Fix requirements marks associate with STAT3. check-in: 9325c1a8 user: drh tags: trunk
2011-10-10
16:06
Enhance sqlite3_analyzer so that it is able to deal with multiplexed databases that have 8+3 filenames. check-in: e5169f9a user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/sqlite.h.in.

  5820   5820   ** and lookaside memory used by all prepared statements associated with
  5821   5821   ** the database connection.)^
  5822   5822   ** ^The highwater mark associated with SQLITE_DBSTATUS_STMT_USED is always 0.
  5823   5823   ** </dd>
  5824   5824   **
  5825   5825   ** [[SQLITE_DBSTATUS_CACHE_HIT]] ^(<dt>SQLITE_DBSTATUS_CACHE_HIT</dt>
  5826   5826   ** <dd>This parameter returns the number of pager cache hits that have
  5827         -** occurred. ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_HIT 
         5827  +** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_HIT 
  5828   5828   ** is always 0.
  5829   5829   ** </dd>
  5830   5830   **
  5831   5831   ** [[SQLITE_DBSTATUS_CACHE_MISS]] ^(<dt>SQLITE_DBSTATUS_CACHE_MISS</dt>
  5832   5832   ** <dd>This parameter returns the number of pager cache misses that have
  5833         -** occurred. ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_MISS 
         5833  +** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_MISS 
  5834   5834   ** is always 0.
  5835   5835   ** </dd>
  5836   5836   ** </dl>
  5837   5837   */
  5838   5838   #define SQLITE_DBSTATUS_LOOKASIDE_USED       0
  5839   5839   #define SQLITE_DBSTATUS_CACHE_USED           1
  5840   5840   #define SQLITE_DBSTATUS_SCHEMA_USED          2

Changes to src/where.c.

   701    701     if( op==TK_VARIABLE ){
   702    702       Vdbe *pReprepare = pParse->pReprepare;
   703    703       int iCol = pRight->iColumn;
   704    704       pVal = sqlite3VdbeGetValue(pReprepare, iCol, SQLITE_AFF_NONE);
   705    705       if( pVal && sqlite3_value_type(pVal)==SQLITE_TEXT ){
   706    706         z = (char *)sqlite3_value_text(pVal);
   707    707       }
   708         -    sqlite3VdbeSetVarmask(pParse->pVdbe, iCol); /* IMP: R-23257-02778 */
          708  +    sqlite3VdbeSetVarmask(pParse->pVdbe, iCol); /* IMP: R-31526-56213 */
   709    709       assert( pRight->op==TK_VARIABLE || pRight->op==TK_REGISTER );
   710    710     }else if( op==TK_STRING ){
   711    711       z = pRight->u.zToken;
   712    712     }
   713    713     if( z ){
   714    714       cnt = 0;
   715    715       while( (c=z[cnt])!=0 && c!=wc[0] && c!=wc[1] && c!=wc[2] ){
................................................................................
   719    719         Expr *pPrefix;
   720    720         *pisComplete = c==wc[0] && z[cnt+1]==0;
   721    721         pPrefix = sqlite3Expr(db, TK_STRING, z);
   722    722         if( pPrefix ) pPrefix->u.zToken[cnt] = 0;
   723    723         *ppPrefix = pPrefix;
   724    724         if( op==TK_VARIABLE ){
   725    725           Vdbe *v = pParse->pVdbe;
   726         -        sqlite3VdbeSetVarmask(v, pRight->iColumn); /* IMP: R-23257-02778 */
          726  +        sqlite3VdbeSetVarmask(v, pRight->iColumn); /* IMP: R-31526-56213 */
   727    727           if( *pisComplete && pRight->u.zToken[1] ){
   728    728             /* If the rhs of the LIKE expression is a variable, and the current
   729    729             ** value of the variable means there is no need to invoke the LIKE
   730    730             ** function, then no OP_Variable will be added to the program.
   731    731             ** This causes problems for the sqlite3_bind_parameter_name()
   732    732             ** API. To workaround them, add a dummy OP_Variable here.
   733    733             */ 
................................................................................
  2633   2633     u8 aff, 
  2634   2634     sqlite3_value **pp
  2635   2635   ){
  2636   2636     if( pExpr->op==TK_VARIABLE
  2637   2637      || (pExpr->op==TK_REGISTER && pExpr->op2==TK_VARIABLE)
  2638   2638     ){
  2639   2639       int iVar = pExpr->iColumn;
  2640         -    sqlite3VdbeSetVarmask(pParse->pVdbe, iVar); /* IMP: R-23257-02778 */
         2640  +    sqlite3VdbeSetVarmask(pParse->pVdbe, iVar); /* IMP: R-31526-56213 */
  2641   2641       *pp = sqlite3VdbeGetValue(pParse->pReprepare, iVar, aff);
  2642   2642       return SQLITE_OK;
  2643   2643     }
  2644   2644     return sqlite3ValueFromExpr(pParse->db, pExpr, SQLITE_UTF8, aff, pp);
  2645   2645   }
  2646   2646   #endif
  2647   2647