Documentation Source Text

Check-in [6b17e6415e]
Login

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

Overview
Comment:Enhance the documentation on PRAGMA integrity_check to match recent implementation enhancements. Add the enhancements to PRAGMA integrity_check to the change log.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 6b17e6415ec5918407fadebb54a44107a15b1d23
User & Date: drh 2014-08-01 03:11:49.094
Context
2014-08-05
20:22
Update the change log for the latest changes. Make it easier to find the "How To Compile" documentation. Remove Nokia from the sponsors list. (check-in: c22649df68 user: drh tags: trunk)
2014-08-01
03:11
Enhance the documentation on PRAGMA integrity_check to match recent implementation enhancements. Add the enhancements to PRAGMA integrity_check to the change log. (check-in: 6b17e6415e user: drh tags: trunk)
2014-07-31
19:04
Add the DISTINCT optimization to the change log for 3.8.6. (check-in: 06696e7778 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to pages/changes.in.
35
36
37
38
39
40
41


42
43
44
45
46
47
48
<li>Increase the maximum value of [SQLITE_MAX_ATTACHED] from 62 to 125.
<li>Trigger automatic reprepares on all prepared statements when [ANALYZE] is
    run.
<li>Ensure that the query planner never tries to use a self-made transient
    index in place of a schema-defined index.
<li>Optimization: Deactivate the [DISTINCT] keyword on subqueries on the
    right-hand side of the [IN operator].


<p><b>Bug Fixes:</b>
<li>Fix a bug in [CREATE INDEX|CREATE UNIQUE INDEX], introduced when [WITHOUT ROWID]
    support added in version 3.8.2, that allows a non-unique NOT NULL column to be
    given a UNIQUE index.
    Ticket [http://www.sqlite.org/src/info/9a6daf340df99ba93c|9a6daf340df99ba93c]
<li>Fix a bug in [R-Tree extension], introduced in the previous release,
    that can cause an







>
>







35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<li>Increase the maximum value of [SQLITE_MAX_ATTACHED] from 62 to 125.
<li>Trigger automatic reprepares on all prepared statements when [ANALYZE] is
    run.
<li>Ensure that the query planner never tries to use a self-made transient
    index in place of a schema-defined index.
<li>Optimization: Deactivate the [DISTINCT] keyword on subqueries on the
    right-hand side of the [IN operator].
<li>Enhanced the [PRAGMA integrity_check] command to detect [UNIQUE] and
    [NOT NULL] constraint violations.
<p><b>Bug Fixes:</b>
<li>Fix a bug in [CREATE INDEX|CREATE UNIQUE INDEX], introduced when [WITHOUT ROWID]
    support added in version 3.8.2, that allows a non-unique NOT NULL column to be
    given a UNIQUE index.
    Ticket [http://www.sqlite.org/src/info/9a6daf340df99ba93c|9a6daf340df99ba93c]
<li>Fix a bug in [R-Tree extension], introduced in the previous release,
    that can cause an
Changes to pages/pragma.in.
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222








1223
1224
1225
1226
1227
1228

1229
1230
1231
1232
1233
1234
1235
1236
1237
}

Pragma integrity_check {
    <p><b>PRAGMA integrity_check;
    <br>PRAGMA integrity_check(</b><i>N</i><b>)</b></p>
    <p>^This pragma does an integrity check of the entire database.  ^The
    integrity_check pragma
    looks for out-of-order records, missing pages, malformed records, and
    corrupt indices.
    ^If the integrity_check pragma finds problems, strings are returned
    (as multiple rows with a single column per row) which describe
    the problems.  ^Pragma integrity_check will return at most <i>N</i>
    errors will be reported before the analysis quits, with N defaulting
    to 100.  ^If pragma integrity_check finds no errors are found, a
    single row with the value 'ok' is returned.</p>








}

Pragma quick_check {
    <p><b>PRAGMA quick_check;
    <br>PRAGMA quick_check(</b><i>N</i><b>)</b></p>
    <p>^The pragma is like [integrity_check] except that it does not verify

    that index content matches table content.  By skipping the verification
    of index content, quick_check is able to run much faster than
    integrity_check.  ^Otherwise the two pragmas are the same.
    </p>
}

DebugPragma parser_trace {
    <p><b>PRAGMA parser_trace = </b><i>boolean</i><b>; </b></p>








|
|



|
|

>
>
>
>
>
>
>
>






>
|
|







1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
}

Pragma integrity_check {
    <p><b>PRAGMA integrity_check;
    <br>PRAGMA integrity_check(</b><i>N</i><b>)</b></p>
    <p>^This pragma does an integrity check of the entire database.  ^The
    integrity_check pragma
    looks for out-of-order records, missing pages, malformed records, missing
    index entries, and UNIQUE and NOT NULL constraint errors.
    ^If the integrity_check pragma finds problems, strings are returned
    (as multiple rows with a single column per row) which describe
    the problems.  ^Pragma integrity_check will return at most <i>N</i>
    errors before the analysis quits, with N defaulting
    to 100.  ^If pragma integrity_check finds no errors, a
    single row with the value 'ok' is returned.</p>

    <p>PRAGMA integrity_check does not find
    [foreign key constraint|FOREIGN KEY] errors.  
    Use the [PRAGMA foreign_key_check] command for to find errors in
    FOREIGN KEY constraints.</p>

    <p>See also the [PRAGMA quick_check] command which does most of the
    checking of PRAGMA integrity_check but runs much faster.</p>
}

Pragma quick_check {
    <p><b>PRAGMA quick_check;
    <br>PRAGMA quick_check(</b><i>N</i><b>)</b></p>
    <p>^The pragma is like [integrity_check] except that it does not verify
    UNIQUE and NOT NULL constraints and does not verify
    that index content matches table content.  By skipping UNIQUE and NOT NULL
    and index consistency checks, quick_check is able to run much faster than
    integrity_check.  ^Otherwise the two pragmas are the same.
    </p>
}

DebugPragma parser_trace {
    <p><b>PRAGMA parser_trace = </b><i>boolean</i><b>; </b></p>