Kbase P48450: Default value is ignored when inserting records into SQL-92 table
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/16/2008 |
|
Status: Unverified
FACT(s) (Environment):
Progress 9.x
SYMPTOM(s):
DEFAULT value is ignored when inserting records into SQL-92 table
CAUSE:
Empty string or null value included in the insert statement overwrites
the default value.
FIX:
Change you insert statement according to the following example:
create table (field1 integer, field2 varchar(10) default 'Hello');
Insert into table(field1) values(1); --> default value 'Hello' is set to field2
Insert into table values(1,''); --> empty string is set to field2