The DEFAULT clause is documented thus in Pervasive.SQL V8:
column-definition ::= column-name data-type [ DEFAULT default-value ]
[ column-constraint [ column-constraint ]... [CASE | COLLATE
collation-name ]
default-value ::= literal
literal ::= 'string'
Quote:
number
{ d 'date-literal' }
{ t 'time-literal' }
{ ts 'timestamp-literal' } |
Note that the value provided to the DEFAULT string is a Literal, and a
literal is defined as a constant value. It is not legal (at least in
this version) to have a function (e.g. NOW()) in this slot.
Goldstar Software Inc.
Building on Btrieve(R) for the Future(SM)
Bill Bach
BillBach (AT) goldstarsoftware (DOT) com
http://www.goldstarsoftware.com
*** Pervasive.SQL Service & Support Classes ***
Coming Soon: Pervasive DataExchange Training!
mbosco51 (AT) hotmail (DOT) com wrote:
Quote:
CREATE TABLE TableName
(
Field1 IDENTITY NOT NULL,
Field2 varchar(20) NULL CASE,
Field3 timestamp DEFAULT NOW NULL
) |