/ Changes On Branch index-info-on-table
Login

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

Changes In Branch index-info-on-table Excluding Merge-Ins

This is equivalent to a diff from b115856408 to fe49fb0313

2016-10-26
13:58
Merge the SQLITE_ENABLE_URI_00_ERROR compile-time option. (check-in: 86675ae0ab user: drh tags: trunk)
12:15
Add compile time option SQLITE_ENABLE_URI_00_ERROR. If defined, any "%00" escape found in a URI is treated as an error. (check-in: e8a9bfece2 user: dan tags: uri-00-error)
2016-10-25
17:28
Merge recent trunk changes, and especially the PRAGMA index_info enhancement which is needed on this branch. (check-in: c3570e462a user: drh tags: est_count_pragma)
15:39
Enhance the "PRAGMA index_info" and "PRAGMA index_xinfo" statements so that they work on WITHOUT ROWID tables and provide information about the underlying index btree that implements the WITHOUT ROWID table. (Leaf check-in: fe49fb0313 user: drh tags: index-info-on-table)
15:06
Add test case to demonstrate a "BEGIN EXCLUSIVE" command returning SQLITE_BUSY_SNAPSHOT. (check-in: b115856408 user: dan tags: trunk)
2016-10-24
01:01
Performance optimization in moveToRoot(). Avoid repeated validity checking of the root page on each call. Once is enough. (check-in: 98795c2dd9 user: drh tags: trunk)

Changes to src/pragma.c.

  1118   1118     }
  1119   1119     break;
  1120   1120   
  1121   1121     case PragTyp_INDEX_INFO: if( zRight ){
  1122   1122       Index *pIdx;
  1123   1123       Table *pTab;
  1124   1124       pIdx = sqlite3FindIndex(db, zRight, zDb);
         1125  +    if( pIdx==0 ){
         1126  +      pTab = sqlite3FindTable(db, zRight, zDb);
         1127  +      if( pTab && !HasRowid(pTab) ) pIdx = sqlite3PrimaryKeyIndex(pTab);
         1128  +    }
  1125   1129       if( pIdx ){
  1126   1130         static const char *azCol[] = {
  1127   1131            "seqno", "cid", "name", "desc", "coll", "key"
  1128   1132         };
  1129   1133         int i;
  1130   1134         int mx;
  1131   1135         if( pPragma->iArg ){

Changes to test/without_rowid1.test.

   323    323   } {1 {CHECK constraint failed: t70a}}
   324    324   do_catchsql_test 7.3 {
   325    325     CREATE TABLE t70b(
   326    326        a INT CHECK( rowid!=33 ),
   327    327        b TEXT PRIMARY KEY
   328    328     ) WITHOUT ROWID;
   329    329   } {1 {no such column: rowid}}
          330  +
          331  +# The PRAGMA index_info and index_xinfo pragmas work on 
          332  +# WITHOUT ROWID tables too, but not on rowid tables.
          333  +#
          334  +do_execsql_test 8.1 {
          335  +  CREATE TABLE t80a(a TEXT, b INT, c BLOB, PRIMARY KEY(c,b));
          336  +  PRAGMA index_info(t80a);
          337  +} {}
          338  +do_execsql_test 8.2 {
          339  +  PRAGMA index_xinfo(t80a);
          340  +} {}
          341  +do_execsql_test 8.3 {
          342  +  CREATE TABLE t80b(a TEXT, b INT, c BLOB, PRIMARY KEY(c,b)) WITHOUT ROWID;
          343  +  PRAGMA index_info(t80b);
          344  +} {0 2 c 1 1 b}
          345  +do_execsql_test 8.4 {
          346  +  PRAGMA index_xinfo(t80b);
          347  +} {0 2 c 0 BINARY 1 1 1 b 0 BINARY 1 2 0 a 0 BINARY 0}
          348  +
   330    349   
   331    350     
   332    351   finish_test