[EMAIL PROTECTED]">I've been using the syntax "PRIMARY KEY (column_name [, column_name ])," without the constraint name, and the "COLUMN_NAME TYPE PRIMARY KEY" syntax for sometime now. I may be admitting to SQL heresy in saying that; but, that's the syntax I've seen in MySQL and in quite a few SQL/database books.After fixing the several obvious syntax errors, it works fine for me:
regression=# CREATE TABLE message
regression-# (
regression(# msgid int4 not null,
regression(# msgtext text,
regression(# CONSTRAINT cons_001_pk PRIMARY KEY (msgid)
regression(# );
NOTICE: CREATE TABLE/PRIMARY KEY will create implicit index 'cons_001_pk' for table 'message'
CREATE
regression=# \d message
Table "message"
Attribute | Type | Modifier
-----------+---------+----------
msgid | integer | not null
msgtext | text |
Primary Key: cons_001_pk
regression=#
Is Cold Fusion perhaps doing strange things to the query behind your
back? None of those CREATE TABLE commands are legal SQL according
to my references.
AFIAK, it's a legal table creation statement.