Allow CAST expressions and unary "+" operators to be used in the DEFAULT

argument of an ALTER TABLE ADD COLUMN and to be understand on the RHS of
range constraints interpreted by STAT3/4.  This involves a rewrite of the
implementation of the CAST operator.

FossilOrigin-Name: 91d8a8d0b792ea5c4fe68fd9caaf3345eddea486
This commit is contained in:
drh
2014-08-25 20:11:52 +00:00
parent f741e0491e
commit 4169e430a2
7 changed files with 84 additions and 117 deletions
+1 -1
View File
@@ -145,7 +145,7 @@ do_test alter4-2.6 {
} {1 {Cannot add a column with non-constant default}}
do_test alter4-2.7 {
catchsql {
alter table t1 add column d default (-+1);
alter table t1 add column d default (-5+1);
}
} {1 {Cannot add a column with non-constant default}}
do_test alter4-2.99 {