1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-24 08:21:29 +03:00

Back out part of (5546): Even though ON CONFLICT clauses on CHECK constraints

are no-ops, if a schema includes them, the database will be unreadable if
we do not at least parse and ignore the clause. (CVS 5548)

FossilOrigin-Name: efcaeb68f943daf135972ae045eff1ca157a7f22
This commit is contained in:
drh
2008-08-08 15:06:21 +00:00
parent 6382033cc5
commit e72e728b64
3 changed files with 9 additions and 9 deletions

View File

@@ -1,5 +1,5 @@
C Round\slookaside\sbuffer\ssizes\sin\sthe\sright\sdirection.\s\sTicket\s#3277.\s(CVS\s5547) C Back\sout\spart\sof\s(5546):\s\sEven\sthough\sON\sCONFLICT\sclauses\son\sCHECK\sconstraints\nare\sno-ops,\sif\sa\sschema\sincludes\sthem,\sthe\sdatabase\swill\sbe\sunreadable\sif\nwe\sdo\snot\sat\sleast\sparse\sand\signore\sthe\sclause.\s(CVS\s5548)
D 2008-08-08T14:33:13 D 2008-08-08T15:06:22
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0 F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
F Makefile.in 2713ea64947be3b35f35d9a3158bb8299c90b019 F Makefile.in 2713ea64947be3b35f35d9a3158bb8299c90b019
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654 F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@@ -137,7 +137,7 @@ F src/os_unix.c fe0dbc35bcd3de49e46b132abfc0f45d6dd6a864
F src/os_win.c aefe9ee26430678a19a058a874e4e2bd91398142 F src/os_win.c aefe9ee26430678a19a058a874e4e2bd91398142
F src/pager.c b6a366f2343e7f127d7e70dbe76cd664336143cd F src/pager.c b6a366f2343e7f127d7e70dbe76cd664336143cd
F src/pager.h 588c1ac195228b2da45c4e5f7ab6c2fd253d1751 F src/pager.h 588c1ac195228b2da45c4e5f7ab6c2fd253d1751
F src/parse.y 3bd91b936a247dbb89a6fb1824cb18c6987f16b0 F src/parse.y 95d377a7c8714d4b68085709482c4220dc3cd778
F src/pragma.c 6e207b4f69901089758c02c02e0bf86ed12a4d8f F src/pragma.c 6e207b4f69901089758c02c02e0bf86ed12a4d8f
F src/prepare.c d9f420808f7d2802258f0bf64103271311e2d87f F src/prepare.c d9f420808f7d2802258f0bf64103271311e2d87f
F src/printf.c 2e984b2507291a7e16d89dc9bb60582904f6247d F src/printf.c 2e984b2507291a7e16d89dc9bb60582904f6247d
@@ -617,7 +617,7 @@ F tool/speedtest16.c c8a9c793df96db7e4933f0852abb7a03d48f2e81
F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
F tool/speedtest8.c 1dbced29de5f59ba2ebf877edcadf171540374d1 F tool/speedtest8.c 1dbced29de5f59ba2ebf877edcadf171540374d1
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
P 4cedc641ed39982ae8cbb9200aa1e2f37c878b73 P c1a9bf3863b7bcc69885e4637f18c6532075f982
R 01f00fc1811b3bcf6084576543aedf2f R 8d0e91da93c2779fa60230021b205285
U drh U drh
Z 42d29333f3f39fd281bf48965af060b7 Z d95263978d00f25283f3bc56c2592eb7

View File

@@ -1 +1 @@
c1a9bf3863b7bcc69885e4637f18c6532075f982 efcaeb68f943daf135972ae045eff1ca157a7f22

View File

@@ -14,7 +14,7 @@
** the parser. Lemon will also generate a header file containing ** the parser. Lemon will also generate a header file containing
** numeric codes for all of the tokens. ** numeric codes for all of the tokens.
** **
** @(#) $Id: parse.y,v 1.249 2008/08/08 14:19:41 drh Exp $ ** @(#) $Id: parse.y,v 1.250 2008/08/08 15:06:22 drh Exp $
*/ */
// All token codes are small integers with #defines that begin with "TK_" // All token codes are small integers with #defines that begin with "TK_"
@@ -313,7 +313,7 @@ tcons ::= PRIMARY KEY LP idxlist(X) autoinc(I) RP onconf(R).
{sqlite3AddPrimaryKey(pParse,X,R,I,0);} {sqlite3AddPrimaryKey(pParse,X,R,I,0);}
tcons ::= UNIQUE LP idxlist(X) RP onconf(R). tcons ::= UNIQUE LP idxlist(X) RP onconf(R).
{sqlite3CreateIndex(pParse,0,0,0,X,R,0,0,0,0);} {sqlite3CreateIndex(pParse,0,0,0,X,R,0,0,0,0);}
tcons ::= CHECK LP expr(E) RP. {sqlite3AddCheckConstraint(pParse,E);} tcons ::= CHECK LP expr(E) RP onconf. {sqlite3AddCheckConstraint(pParse,E);}
tcons ::= FOREIGN KEY LP idxlist(FA) RP tcons ::= FOREIGN KEY LP idxlist(FA) RP
REFERENCES nm(T) idxlist_opt(TA) refargs(R) defer_subclause_opt(D). { REFERENCES nm(T) idxlist_opt(TA) refargs(R) defer_subclause_opt(D). {
sqlite3CreateForeignKey(pParse, FA, &T, TA, R); sqlite3CreateForeignKey(pParse, FA, &T, TA, R);