System.Data.SQLite
Check-in [42082ffc4d]
Not logged in

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

Overview
Comment:Add support for new DBCONFIG options from the SQLite core library. Pursuant to [03b6b0edd7].
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 42082ffc4dd6d8e772116803af9e639e40e8a9d7
User & Date: mistachkin 2019-10-05 03:32:17
References
2019-10-05
03:32 Closed ticket [03b6b0edd7]: Complete support of native SQLITE_DBCONFIG_* parameters plus 4 other changes artifact: acbba8f008 user: mistachkin
Context
2019-10-06
00:54
Fix 'checkForSecurityProtocols' test suite helper procedure for use with .NET Core. check-in: 385a304305 user: mistachkin tags: trunk
2019-10-05
17:47
Initial work on supporting the .NET Standard 2.1 (and .NET Core 3.0). check-in: c1dd57b1a1 user: mistachkin tags: netStandard21
03:32
Add support for new DBCONFIG options from the SQLite core library. Pursuant to [03b6b0edd7]. check-in: 42082ffc4d user: mistachkin tags: trunk
03:01
Move test suite SecurityProtocol handling into the vendor script and make it more robust. check-in: f68d495bea user: mistachkin tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to Doc/Extra/Provider/version.html.

    42     42       </div>
    43     43       <div id="mainSection">
    44     44       <div id="mainBody">
    45     45       <h1 class="heading">Version History</h1>
    46     46       <p><b>1.0.112.0 - October XX, 2019 <font color="red">(release scheduled)</font></b></p>
    47     47       <ul>
    48     48         <li>Updated to <a href="https://www.sqlite.org/releaselog/3_30_0.html">SQLite 3.30.0</a>.</li>
           49  +      <li>Add support for new DBCONFIG options from the SQLite core library. Pursuant to <a href="https://system.data.sqlite.org/index.html/info/03b6b0edd7">[03b6b0edd7]</a>.</li>
    49     50       </ul>
    50     51       <p><b>1.0.111.0 - June 10, 2019</b></p>
    51     52       <ul>
    52     53         <li>Updated to <a href="https://www.sqlite.org/releaselog/3_28_0.html">SQLite 3.28.0</a>.</li>
    53     54         <li>Add No_SQLiteLog environment variable.</li>
    54     55       </ul>
    55     56       <p><b>1.0.110.0 - March 4, 2019</b></p>

Changes to System.Data.SQLite/SQLite3.cs.

  3073   3073               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_ENABLE_TRIGGER: // int int*
  3074   3074               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_ENABLE_FTS3_TOKENIZER: // int int*
  3075   3075               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_ENABLE_LOAD_EXTENSION: // int int*
  3076   3076               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_NO_CKPT_ON_CLOSE: // int int*
  3077   3077               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_ENABLE_QPSG: // int int*
  3078   3078               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_TRIGGER_EQP: // int int*
  3079   3079               case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_RESET_DATABASE: // int int*
         3080  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_DEFENSIVE: // int int*
         3081  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_WRITABLE_SCHEMA: // int int*
         3082  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_LEGACY_ALTER_TABLE: // int int*
         3083  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_DQS_DML: // int int*
         3084  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_DQS_DDL: // int int*
         3085  +            case SQLiteConfigDbOpsEnum.SQLITE_DBCONFIG_ENABLE_VIEW: // int int*
  3080   3086                   {
  3081   3087                       if (!(value is bool))
  3082   3088                       {
  3083   3089                           throw new SQLiteException(HelperMethods.StringFormat(
  3084   3090                               CultureInfo.CurrentCulture,
  3085   3091                               "configuration value type mismatch, must be of type {0}",
  3086   3092                               typeof(bool)));

Changes to System.Data.SQLite/SQLiteBase.cs.

  1602   1602   
  1603   1603         /// <summary>
  1604   1604         /// This option is used as part of the process to reset a database back
  1605   1605         /// to an empty state.  Because resetting a database is destructive and
  1606   1606         /// irreversible, the process requires the use of this obscure flag and
  1607   1607         /// multiple steps to help ensure that it does not happen by accident.
  1608   1608         /// </summary>
  1609         -      SQLITE_DBCONFIG_RESET_DATABASE = 1009 // int int*
         1609  +      SQLITE_DBCONFIG_RESET_DATABASE = 1009, // int int*
         1610  +
         1611  +      /// <summary>
         1612  +      /// This option activates or deactivates the "defensive" flag for a
         1613  +      /// database connection.  When the defensive flag is enabled, language
         1614  +      /// features that allow ordinary SQL to deliberately corrupt the database
         1615  +      /// file are disabled.  The disabled features include but are not limited
         1616  +      /// to the following:
         1617  +      /// <![CDATA[<ul>]]>
         1618  +      /// <![CDATA[<li>]]>
         1619  +      /// The PRAGMA writable_schema=ON statement.
         1620  +      /// <![CDATA[</li>]]>
         1621  +      /// <![CDATA[<li>]]>
         1622  +      /// The PRAGMA journal_mode=OFF statement.
         1623  +      /// <![CDATA[</li>]]>
         1624  +      /// <![CDATA[<li>]]>
         1625  +      /// Writes to the sqlite_dbpage virtual table.
         1626  +      /// <![CDATA[</li>]]>
         1627  +      /// <![CDATA[<li>]]>
         1628  +      /// Direct writes to shadow tables.
         1629  +      /// <![CDATA[</li>]]>
         1630  +      /// <![CDATA[</ul>]]>
         1631  +      /// </summary>
         1632  +      SQLITE_DBCONFIG_DEFENSIVE = 1010, // int int*
         1633  +
         1634  +      /// <summary>
         1635  +      /// This option activates or deactivates the "writable_schema" flag.
         1636  +      /// </summary>
         1637  +      SQLITE_DBCONFIG_WRITABLE_SCHEMA = 1011, // int int*
         1638  +
         1639  +      /// <summary>
         1640  +      /// This option activates or deactivates the legacy behavior of the ALTER
         1641  +      /// TABLE RENAME command such it behaves as it did prior to version 3.24.0
         1642  +      /// (2018-06-04).
         1643  +      /// </summary>
         1644  +      SQLITE_DBCONFIG_LEGACY_ALTER_TABLE = 1012, // int int*
         1645  +
         1646  +      /// <summary>
         1647  +      /// This option activates or deactivates the legacy double-quoted string
         1648  +      /// literal misfeature for DML statement only, that is DELETE, INSERT,
         1649  +      /// SELECT, and UPDATE statements.
         1650  +      /// </summary>
         1651  +      SQLITE_DBCONFIG_DQS_DML = 1013, // int int*
         1652  +
         1653  +      /// <summary>
         1654  +      /// This option activates or deactivates the legacy double-quoted string
         1655  +      /// literal misfeature for DDL statements, such as CREATE TABLE and CREATE
         1656  +      /// INDEX.
         1657  +      /// </summary>
         1658  +      SQLITE_DBCONFIG_DQS_DDL = 1014, // int int*
         1659  +
         1660  +      /// <summary>
         1661  +      /// This option is used to enable or disable CREATE VIEW.
         1662  +      /// </summary>
         1663  +      SQLITE_DBCONFIG_ENABLE_VIEW = 1015 // int int*
  1610   1664     }
  1611   1665   
  1612   1666     // These are the options to the internal sqlite3_config call.
  1613   1667     internal enum SQLiteConfigOpsEnum
  1614   1668     {
  1615   1669       SQLITE_CONFIG_NONE = 0, // nil
  1616   1670       SQLITE_CONFIG_SINGLETHREAD = 1, // nil

Changes to Tests/basic.eagle.

  4957   4957     lappend dbConfigs SQLITE_DBCONFIG_ENABLE_FKEY; # int int*
  4958   4958     lappend dbConfigs SQLITE_DBCONFIG_ENABLE_TRIGGER; # int int*
  4959   4959     lappend dbConfigs SQLITE_DBCONFIG_ENABLE_FTS3_TOKENIZER; # int int*
  4960   4960     lappend dbConfigs SQLITE_DBCONFIG_ENABLE_LOAD_EXTENSION; # int int*
  4961   4961     lappend dbConfigs SQLITE_DBCONFIG_NO_CKPT_ON_CLOSE; # int int*
  4962   4962     lappend dbConfigs SQLITE_DBCONFIG_ENABLE_QPSG; # int int*
  4963   4963     lappend dbConfigs SQLITE_DBCONFIG_TRIGGER_EQP; # int int*
         4964  +  lappend dbConfigs SQLITE_DBCONFIG_RESET_DATABASE; # int int*
         4965  +  lappend dbConfigs SQLITE_DBCONFIG_DEFENSIVE; # int int*
         4966  +  lappend dbConfigs SQLITE_DBCONFIG_WRITABLE_SCHEMA; # int int*
         4967  +  lappend dbConfigs SQLITE_DBCONFIG_LEGACY_ALTER_TABLE; # int int*
         4968  +  lappend dbConfigs SQLITE_DBCONFIG_DQS_DML; # int int*
         4969  +  lappend dbConfigs SQLITE_DBCONFIG_DQS_DDL; # int int*
         4970  +  lappend dbConfigs SQLITE_DBCONFIG_ENABLE_VIEW; # int int*
  4964   4971   
  4965   4972     set connection [getDbConnection]
  4966   4973   
  4967   4974     foreach dbConfig $dbConfigs {
  4968   4975       switch -exact -- $dbConfig {
  4969   4976         SQLITE_DBCONFIG_NONE {
  4970   4977           set value null
................................................................................
  5031   5038     }
  5032   5039   
  5033   5040     unset -nocomplain current highwater ints count size ptr value
  5034   5041     unset -nocomplain result dbConfig dbConfigs
  5035   5042     unset -nocomplain connection db fileName
  5036   5043   } -constraints {eagle monoBug28 command.sql compile.DATA SQLite\
  5037   5044   System.Data.SQLite} -match regexp -result {^\{\} \{\} \{\} \{\} \{\} \{\} \{\}\
  5038         -\{\} \{\} \{\} Ok 0 0 Ok \d+ \d+ True True$}}
         5045  +\{\} \{\} \{\} \{\} \{\} \{\} \{\} \{\} \{\} \{\} Ok 0 0 Ok \d+ \d+ True True$}}
  5039   5046   
  5040   5047   ###############################################################################
  5041   5048   
  5042   5049   runTest {test data-1.96 {connection pool interaction with read-only} -setup {
  5043   5050     catch {
  5044   5051       object invoke -flags +NonPublic \
  5045   5052           System.Data.SQLite.SQLiteConnectionPool _poolOpened 0

Changes to readme.htm.

   208    208   <h2><b>Version History</b></h2>
   209    209   
   210    210   <p>
   211    211       <b>1.0.112.0 - October XX, 2019 <font color="red">(release scheduled)</font></b>
   212    212   </p>
   213    213   <ul>
   214    214       <li>Updated to <a href="https://www.sqlite.org/releaselog/3_30_0.html">SQLite 3.30.0</a>.</li>
          215  +    <li>Add support for new DBCONFIG options from the SQLite core library. Pursuant to [03b6b0edd7].</li>
   215    216   </ul>
   216    217   <p>
   217    218       <b>1.0.111.0 - June 10, 2019</b>
   218    219   </p>
   219    220   <ul>
   220    221       <li>Updated to <a href="https://www.sqlite.org/releaselog/3_28_0.html">SQLite 3.28.0</a>.</li>
   221    222       <li>Add No_SQLiteLog environment variable.</li>

Changes to www/news.wiki.

    45     45   <div align="center"><h2><b>Version History</b></h2></div>
    46     46   
    47     47   <p>
    48     48       <b>1.0.112.0 - October XX, 2019 <font color="red">(release scheduled)</font></b>
    49     49   </p>
    50     50   <ul>
    51     51       <li>Updated to [https://www.sqlite.org/releaselog/3_30_0.html|SQLite 3.30.0].</li>
           52  +    <li>Add support for new DBCONFIG options from the SQLite core library. Pursuant to [03b6b0edd7].</li>
    52     53   </ul>
    53     54   <p>
    54     55       <b>1.0.111.0 - June 10, 2019</b>
    55     56   </p>
    56     57   <ul>
    57     58       <li>Updated to [https://www.sqlite.org/releaselog/3_28_0.html|SQLite 3.28.0].</li>
    58     59       <li>Add No_SQLiteLog environment variable.</li>