/ Check-in [008112bc]
Login

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

Overview
Comment:Omit deprecated PRAGMAs when compiling with the -DSQLITE_OMIT_DEPRECATED option.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256:008112bcef561a8a3ebfb007cbef36cbc0071f547e6ebdba3d3bbb39e2c48c7a
User & Date: drh 2019-01-24 16:07:18
References
2019-02-06
00:11
Back out check-in [008112bcef561a8], reenabling deprecated PRAGMAs when the SQLITE_OMIT_DEPRECATED compile-time option is used, because way too many TH3 tests depend on those deprecated PRAGMAs. check-in: 9dbf512d user: drh tags: trunk
Context
2019-02-06
00:11
Back out check-in [008112bcef561a8], reenabling deprecated PRAGMAs when the SQLITE_OMIT_DEPRECATED compile-time option is used, because way too many TH3 tests depend on those deprecated PRAGMAs. check-in: 9dbf512d user: drh tags: trunk
2019-01-24
16:51
While PRAGMA full_column_names is off (the default) do not make changes to the short_column_names pragma when computing the column names for subqueries. Leaf check-in: 718ead55 user: drh tags: literal-column-names
16:27
Fix a problem with running ALTER TABLE on a schema that contains expressions of the type "col IN ()" (empty set on RHS of IN operator). check-in: 2d9cd067 user: dan tags: trunk
16:07
Omit deprecated PRAGMAs when compiling with the -DSQLITE_OMIT_DEPRECATED option. check-in: 008112bc user: drh tags: trunk
15:51
Make sure the column name flags are restored correctly after an error inside of sqlite3ResultSetOfSelect(). check-in: b1601db7 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/pragma.h.

   207    207    {/* zName:     */ "compile_options",
   208    208     /* ePragTyp:  */ PragTyp_COMPILE_OPTIONS,
   209    209     /* ePragFlg:  */ PragFlg_Result0,
   210    210     /* ColNames:  */ 0, 0,
   211    211     /* iArg:      */ 0 },
   212    212   #endif
   213    213   #if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
          214  +#if !defined(SQLITE_OMIT_DEPRECATED)
   214    215    {/* zName:     */ "count_changes",
   215    216     /* ePragTyp:  */ PragTyp_FLAG,
   216    217     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   217    218     /* ColNames:  */ 0, 0,
   218    219     /* iArg:      */ SQLITE_CountRows },
          220  +#endif
   219    221   #endif
   220    222   #if !defined(SQLITE_OMIT_PAGER_PRAGMAS) && SQLITE_OS_WIN
          223  +#if !defined(SQLITE_OMIT_DEPRECATED)
   221    224    {/* zName:     */ "data_store_directory",
   222    225     /* ePragTyp:  */ PragTyp_DATA_STORE_DIRECTORY,
   223    226     /* ePragFlg:  */ PragFlg_NoColumns1,
   224    227     /* ColNames:  */ 0, 0,
   225    228     /* iArg:      */ 0 },
          229  +#endif
   226    230   #endif
   227    231   #if !defined(SQLITE_OMIT_SCHEMA_VERSION_PRAGMAS)
   228    232    {/* zName:     */ "data_version",
   229    233     /* ePragTyp:  */ PragTyp_HEADER_VALUE,
   230    234     /* ePragFlg:  */ PragFlg_ReadOnly|PragFlg_Result0,
   231    235     /* ColNames:  */ 0, 0,
   232    236     /* iArg:      */ BTREE_DATA_VERSION },
................................................................................
   234    238   #if !defined(SQLITE_OMIT_SCHEMA_PRAGMAS)
   235    239    {/* zName:     */ "database_list",
   236    240     /* ePragTyp:  */ PragTyp_DATABASE_LIST,
   237    241     /* ePragFlg:  */ PragFlg_NeedSchema|PragFlg_Result0,
   238    242     /* ColNames:  */ 35, 3,
   239    243     /* iArg:      */ 0 },
   240    244   #endif
   241         -#if !defined(SQLITE_OMIT_PAGER_PRAGMAS) && !defined(SQLITE_OMIT_DEPRECATED)
          245  +#if !defined(SQLITE_OMIT_PAGER_PRAGMAS)
          246  +#if !defined(SQLITE_OMIT_DEPRECATED)
   242    247    {/* zName:     */ "default_cache_size",
   243    248     /* ePragTyp:  */ PragTyp_DEFAULT_CACHE_SIZE,
   244    249     /* ePragFlg:  */ PragFlg_NeedSchema|PragFlg_Result0|PragFlg_SchemaReq|PragFlg_NoColumns1,
   245    250     /* ColNames:  */ 45, 1,
   246    251     /* iArg:      */ 0 },
          252  +#endif
   247    253   #endif
   248    254   #if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
   249    255   #if !defined(SQLITE_OMIT_FOREIGN_KEY) && !defined(SQLITE_OMIT_TRIGGER)
   250    256    {/* zName:     */ "defer_foreign_keys",
   251    257     /* ePragTyp:  */ PragTyp_FLAG,
   252    258     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   253    259     /* ColNames:  */ 0, 0,
   254    260     /* iArg:      */ SQLITE_DeferFKs },
   255    261   #endif
   256    262   #endif
   257    263   #if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
          264  +#if !defined(SQLITE_OMIT_DEPRECATED)
   258    265    {/* zName:     */ "empty_result_callbacks",
   259    266     /* ePragTyp:  */ PragTyp_FLAG,
   260    267     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   261    268     /* ColNames:  */ 0, 0,
   262    269     /* iArg:      */ SQLITE_NullCallback },
          270  +#endif
   263    271   #endif
   264    272   #if !defined(SQLITE_OMIT_UTF16)
   265    273    {/* zName:     */ "encoding",
   266    274     /* ePragTyp:  */ PragTyp_ENCODING,
   267    275     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   268    276     /* ColNames:  */ 0, 0,
   269    277     /* iArg:      */ 0 },
................................................................................
   295    303    {/* zName:     */ "freelist_count",
   296    304     /* ePragTyp:  */ PragTyp_HEADER_VALUE,
   297    305     /* ePragFlg:  */ PragFlg_ReadOnly|PragFlg_Result0,
   298    306     /* ColNames:  */ 0, 0,
   299    307     /* iArg:      */ BTREE_FREE_PAGE_COUNT },
   300    308   #endif
   301    309   #if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
          310  +#if !defined(SQLITE_OMIT_DEPRECATED)
   302    311    {/* zName:     */ "full_column_names",
   303    312     /* ePragTyp:  */ PragTyp_FLAG,
   304    313     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   305    314     /* ColNames:  */ 0, 0,
   306    315     /* iArg:      */ SQLITE_FullColNames },
          316  +#endif
          317  +#endif
          318  +#if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
   307    319    {/* zName:     */ "fullfsync",
   308    320     /* ePragTyp:  */ PragTyp_FLAG,
   309    321     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   310    322     /* ColNames:  */ 0, 0,
   311    323     /* iArg:      */ SQLITE_FullFSync },
   312    324   #endif
   313    325   #if !defined(SQLITE_OMIT_SCHEMA_PRAGMAS)
................................................................................
   526    538    {/* zName:     */ "secure_delete",
   527    539     /* ePragTyp:  */ PragTyp_SECURE_DELETE,
   528    540     /* ePragFlg:  */ PragFlg_Result0,
   529    541     /* ColNames:  */ 0, 0,
   530    542     /* iArg:      */ 0 },
   531    543   #endif
   532    544   #if !defined(SQLITE_OMIT_FLAG_PRAGMAS)
          545  +#if !defined(SQLITE_OMIT_DEPRECATED)
   533    546    {/* zName:     */ "short_column_names",
   534    547     /* ePragTyp:  */ PragTyp_FLAG,
   535    548     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   536    549     /* ColNames:  */ 0, 0,
   537    550     /* iArg:      */ SQLITE_ShortColNames },
          551  +#endif
   538    552   #endif
   539    553    {/* zName:     */ "shrink_memory",
   540    554     /* ePragTyp:  */ PragTyp_SHRINK_MEMORY,
   541    555     /* ePragFlg:  */ PragFlg_NoColumns,
   542    556     /* ColNames:  */ 0, 0,
   543    557     /* iArg:      */ 0 },
   544    558    {/* zName:     */ "soft_heap_limit",
................................................................................
   583    597   #endif
   584    598   #if !defined(SQLITE_OMIT_PAGER_PRAGMAS)
   585    599    {/* zName:     */ "temp_store",
   586    600     /* ePragTyp:  */ PragTyp_TEMP_STORE,
   587    601     /* ePragFlg:  */ PragFlg_Result0|PragFlg_NoColumns1,
   588    602     /* ColNames:  */ 0, 0,
   589    603     /* iArg:      */ 0 },
          604  +#endif
          605  +#if !defined(SQLITE_OMIT_PAGER_PRAGMAS)
          606  +#if !defined(SQLITE_OMIT_DEPRECATED)
   590    607    {/* zName:     */ "temp_store_directory",
   591    608     /* ePragTyp:  */ PragTyp_TEMP_STORE_DIRECTORY,
   592    609     /* ePragFlg:  */ PragFlg_NoColumns1,
   593    610     /* ColNames:  */ 0, 0,
   594    611     /* iArg:      */ 0 },
          612  +#endif
   595    613   #endif
   596    614   #if defined(SQLITE_HAS_CODEC)
   597    615    {/* zName:     */ "textkey",
   598    616     /* ePragTyp:  */ PragTyp_KEY,
   599    617     /* ePragFlg:  */ 0,
   600    618     /* ColNames:  */ 0, 0,
   601    619     /* iArg:      */ 4 },

Changes to tool/mkpragmatab.tcl.

    21     21   set flagMeaning(NoColumns1) {zero columns if RHS argument is present}
    22     22   
    23     23   set pragma_def {
    24     24     NAME: full_column_names
    25     25     TYPE: FLAG
    26     26     ARG:  SQLITE_FullColNames
    27     27     IF:   !defined(SQLITE_OMIT_FLAG_PRAGMAS)
           28  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
    28     29   
    29     30     NAME: short_column_names
    30     31     TYPE: FLAG
    31     32     ARG:  SQLITE_ShortColNames
    32     33     IF:   !defined(SQLITE_OMIT_FLAG_PRAGMAS)
           34  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
    33     35   
    34     36     NAME: count_changes
    35     37     TYPE: FLAG
    36     38     ARG:  SQLITE_CountRows
    37     39     IF:   !defined(SQLITE_OMIT_FLAG_PRAGMAS)
           40  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
    38     41   
    39     42     NAME: empty_result_callbacks
    40     43     TYPE: FLAG
    41     44     ARG:  SQLITE_NullCallback
    42     45     IF:   !defined(SQLITE_OMIT_FLAG_PRAGMAS)
           46  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
    43     47   
    44     48     NAME: legacy_file_format
    45     49     TYPE: FLAG
    46     50     ARG:  SQLITE_LegacyFileFmt
    47     51     IF:   !defined(SQLITE_OMIT_FLAG_PRAGMAS)
    48     52   
    49     53     NAME: fullfsync
................................................................................
   148    152     NAME: cell_size_check
   149    153     TYPE: FLAG
   150    154     ARG:  SQLITE_CellSizeCk
   151    155   
   152    156     NAME: default_cache_size
   153    157     FLAG: NeedSchema Result0 SchemaReq NoColumns1
   154    158     COLS: cache_size
   155         -  IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS) && !defined(SQLITE_OMIT_DEPRECATED)
          159  +  IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS)
          160  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
          161  +
   156    162   
   157    163     NAME: page_size
   158    164     FLAG: Result0 SchemaReq NoColumns1
   159    165     IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS)
   160    166   
   161    167     NAME: secure_delete
   162    168     FLAG: Result0
................................................................................
   201    207     NAME: temp_store
   202    208     FLAG: Result0 NoColumns1
   203    209     IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS)
   204    210   
   205    211     NAME: temp_store_directory
   206    212     FLAG: NoColumns1
   207    213     IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS)
          214  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
   208    215   
   209    216     NAME: data_store_directory
   210    217     FLAG: NoColumns1
   211    218     IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS) && SQLITE_OS_WIN
          219  +  IF:   !defined(SQLITE_OMIT_DEPRECATED)
   212    220   
   213    221     NAME: lock_proxy_file
   214    222     FLAG: NoColumns1
   215    223     IF:   !defined(SQLITE_OMIT_PAGER_PRAGMAS) && SQLITE_ENABLE_LOCKING_STYLE
   216    224   
   217    225     NAME: synchronous
   218    226     FLAG: NeedSchema Result0 SchemaReq NoColumns1