SQLite

Check-in [38461a7acb]
Login

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

Overview
Comment:Update the documentation to reflect the new capabilities of PRAGMA integrity_check. Rewording in the VACUUM documentation. (CVS 1025)
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 38461a7acb5281edd7078b1b3f227bb45f281757
User & Date: drh 2003-06-15 23:49:39.000
Context
2003-06-16
00:16
Preserve blank lines in the middle of SQL statements in the shell. Ticket #352 (CVS 1026) (check-in: bcf5eeecdf user: drh tags: trunk)
2003-06-15
23:49
Update the documentation to reflect the new capabilities of PRAGMA integrity_check. Rewording in the VACUUM documentation. (CVS 1025) (check-in: 38461a7acb user: drh tags: trunk)
23:42
Enhance the "PRAGMA integrity_check" command to verify that all indices are correctly constructed. New calls to integrity_check are made in the test suite. These changes are intended to prevent any future problems such as seen in ticket #334. (CVS 1024) (check-in: c9734c2707 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to www/lang.tcl.
1
2
3
4
5
6
7
8
9
10
11
#
# Run this Tcl script to generate the sqlite.html file.
#
set rcsid {$Id: lang.tcl,v 1.62 2003/06/15 10:29:25 jplyon Exp $}

puts {<html>
<head>
  <title>Query Language Understood By SQLite</title>
</head>
<body bgcolor=white>
<h1 align=center>



|







1
2
3
4
5
6
7
8
9
10
11
#
# Run this Tcl script to generate the sqlite.html file.
#
set rcsid {$Id: lang.tcl,v 1.63 2003/06/15 23:49:39 drh Exp $}

puts {<html>
<head>
  <title>Query Language Understood By SQLite</title>
</head>
<body bgcolor=white>
<h1 align=center>
1359
1360
1361
1362
1363
1364
1365
1366

1367
1368
1369
1370
1371
1372
1373
    <p>For each index on the named table, invoke the callback function
    once with information about that index.  Arguments include the
    index name and a flag to indicate whether or not the index must be
    unique.</p></li>

<li><p><b>PRAGMA integrity_check;</b></p>
    <p>The command does an integrity check of the entire database.  It
    looks for out-of-order records, missing pages, and malformed records.

    If any problems are found, then a single string is returned which is
    a description of all problems.  If everything is in order, "ok" is
    returned.</p></li>

<li><p><b>PRAGMA parser_trace = ON; </b>(1)<b>
    <br>PRAGMA parser_trace = OFF;</b> (0)</p>
    <p>Turn tracing of the SQL parser inside of the







|
>







1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
    <p>For each index on the named table, invoke the callback function
    once with information about that index.  Arguments include the
    index name and a flag to indicate whether or not the index must be
    unique.</p></li>

<li><p><b>PRAGMA integrity_check;</b></p>
    <p>The command does an integrity check of the entire database.  It
    looks for out-of-order records, missing pages, malformed records, and
    corrupt indices.
    If any problems are found, then a single string is returned which is
    a description of all problems.  If everything is in order, "ok" is
    returned.</p></li>

<li><p><b>PRAGMA parser_trace = ON; </b>(1)<b>
    <br>PRAGMA parser_trace = OFF;</b> (0)</p>
    <p>Turn tracing of the SQL parser inside of the
1603
1604
1605
1606
1607
1608
1609
1610

1611
1612
1613
1614
1615

1616
1617
1618
1619
1620
1621
1622
<p>The VACUUM command is an SQLite extension modelled after a similar
command found in PostgreSQL.  If VACUUM is invoked with the name of a
table or index then it is suppose to clean up the named table or index.
In version 1.0 of SQLite, the VACUUM command would invoke 
<b>gdbm_reorganize()</b> to clean up the backend database file.</p>

<p>
VACUUM became a no-op for version 2.0.0 of SQLite. 

The command was reactivated with version 2.8.1.  It now cleans
the database by copying its contents to a temporary database file, and 
reloading the database file from it.  This will eliminate free pages, 
align table data to be contiguous, and otherwise clean up the database 
file structure.  The index or table name argument is now ignored.</p>


<p>This command will fail if there is an active transaction.  This 
command has no effect on an in-memory database.</p>
}


Section {SQLite keywords} keywords







|
>
|
|
|
|
|
>







1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
<p>The VACUUM command is an SQLite extension modelled after a similar
command found in PostgreSQL.  If VACUUM is invoked with the name of a
table or index then it is suppose to clean up the named table or index.
In version 1.0 of SQLite, the VACUUM command would invoke 
<b>gdbm_reorganize()</b> to clean up the backend database file.</p>

<p>
VACUUM became a no-op when the GDBM backend was removed from
SQLITE in version 2.0.0.
VACUUM was reimplimented in version 2.8.1.  It now cleans
the database by copying its contents to a temporary database file and 
reloading the original database file from the copy.  This will eliminate 
free pages,  align table data to be contiguous, and otherwise clean up 
the database file structure.  The index or table name argument is now
ignored.</p>

<p>This command will fail if there is an active transaction.  This 
command has no effect on an in-memory database.</p>
}


Section {SQLite keywords} keywords