Document the fact that SQLite allows NULL values in PRIMARY KEY columns

and the fact that we might design to change this in the future.
Ticket #518. (CVS 3373)

FossilOrigin-Name: b99d845ef4776595022c6fb855e582cfe6ef2f9f
This commit is contained in:
drh
2006-08-29 13:08:37 +00:00
parent 80e8be9337
commit e07b862e71
3 changed files with 20 additions and 8 deletions
+6 -6
View File
@@ -1,5 +1,5 @@
C Improved\sbuilt-in\shelp\sin\sthe\scommand-line\sshell.\s\sEnable\sthe\nfulltext\ssearch\sextension\sin\sthe\sTCL\sinterface.\s(CVS\s3372)
D 2006-08-29T12:04:19
C Document\sthe\sfact\sthat\sSQLite\sallows\sNULL\svalues\sin\sPRIMARY\sKEY\scolumns\nand\sthe\sfact\sthat\swe\smight\sdesign\sto\schange\sthis\sin\sthe\sfuture.\nTicket\s#518.\s(CVS\s3373)
D 2006-08-29T13:08:38
F Makefile.in 8e7f9ecebab2c6e0f3db20ff129a8f9405ab64f8
F Makefile.linux-gcc 2d8574d1ba75f129aba2019f0b959db380a90935
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
@@ -366,7 +366,7 @@ F www/fullscanb.gif f7c94cb227f060511f8909e10f570157263e9a25
F www/index-ex1-x-b.gif f9b1d85c3fa2435cf38b15970c7e3aa1edae23a3
F www/index.tcl 7b9c5747a838501dace958131755651d6ca31adb
F www/indirect1b1.gif adfca361d2df59e34f9c5cac52a670c2bfc303a1
F www/lang.tcl 2cdc7d6a897d8f9da20989985d76326e76afe6c4
F www/lang.tcl 529f5f0f44b55f26cdb66c6547a86b1332e1144a
F www/lockingv3.tcl f59b19d6c8920a931f096699d6faaf61c05db55f
F www/mingw.tcl d96b451568c5d28545fefe0c80bee3431c73f69c
F www/nulls.tcl ec35193f92485b87b90a994a01d0171b58823fcf
@@ -388,7 +388,7 @@ F www/tclsqlite.tcl bb0d1357328a42b1993d78573e587c6dcbc964b9
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl 890248cf7b70e60c383b0e84d77d5132b3ead42b
F www/whentouse.tcl 97e2b5cd296f7d8057e11f44427dea8a4c2db513
P 58006e38af760b53cf72bf127d7c7b8a619a1282
R 29f7ed7a0d966745a2c83716a5630c77
P 9763b4bfd5f0579f9fb821899ffa8bfe650054d7
R e72221fee1f8d400d3a9ceae8a3d3fc0
U drh
Z 1df6398b1b50a7becef0bc2a58ad5ecd
Z 7758aacd5468f280d9ccb11e2061d137
+1 -1
View File
@@ -1 +1 @@
9763b4bfd5f0579f9fb821899ffa8bfe650054d7
b99d845ef4776595022c6fb855e582cfe6ef2f9f
+13 -1
View File
@@ -1,7 +1,7 @@
#
# Run this Tcl script to generate the lang-*.html files.
#
set rcsid {$Id: lang.tcl,v 1.115 2006/08/16 22:58:50 drh Exp $}
set rcsid {$Id: lang.tcl,v 1.116 2006/08/29 13:08:38 drh Exp $}
source common.tcl
if {[llength $argv]>0} {
@@ -564,6 +564,18 @@ that B-Tree keys are automatically generated. Additional detail
on automatic B-Tree key generation is available
<a href="autoinc.html">separately</a>.</p>
<p>According to the SQL standard, PRIMARY KEY should imply NOT NULL.
Unfortunately, due to a long-standing coding oversight, this is not
the case in SQLite. SQLite allows NULL values
in a PRIMARY KEY column. We could change SQLite to conform to the
standard (and we might do so in the future), but by the time the
oversight was discovered, SQLite was in such wide use that we feared
breaking legacy code if we fixed the problem. So for now we have
chosen to contain allowing NULLs in PRIMARY KEY columns.
Developers should be aware, however, that we may change SQLite to
conform to the SQL standard in future and should design new programs
accordingly.</p>
<p>If the "TEMP" or "TEMPORARY" keyword occurs in between "CREATE"
and "TABLE" then the table that is created is only visible
within that same database connection