Syntax error in CREATE TABLE statement. (Error 3290)

Z

zufie

I am trying to Create a table from DDL code.

Upon running the query I get the error: Syntax error in CREATE TABLE
statement. (Error 3290)

Here is my code after making many changes to it:

CREATE TABLE ACCOUNTABILITY (
OBJECTID number (22) NOT NULL,
OBJECTOWNERID decimal (22),
COMMISOID decimal (22),
RESPONOID decimal (22),
COMMISOBJECTTYPE CHARACTER (5),
RESPONOBJECTTYPE CHARACTER (5),
ACCOUNTYPEOID decimal (22),
BEGINDATE TIMESTAMP,
ENDDATE TIMESTAMP,
OBJECTTYPE CHARACTER (5),
ACL decimal (22),
REPLICNUMBER INTEGER,
ROWLASTCHANGE TIMESTAMP NOT NULL)
;

Any suggestions? I am all ears and eyes.

Zuf
 
J

John Spencer

Are you trying to create this table in JET table or an ACE table (the "native"
Access databases?

If so, check out

For a list of the names to use for the field types, see:
Field type names (JET, DDL, DAO and ADOX)
at:
http://allenbrowne.com/ser-49.html

For instance
COMMISOBJECTTYPE Text(5)
BeginDate DateTime
EndDate DateTime

By the way TIMESTAMP is not a date or time field.

John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
 
B

Bob Barrows

zufie said:
I am trying to Create a table from DDL code.

Upon running the query I get the error: Syntax error in CREATE TABLE
statement. (Error 3290)

Here is my code after making many changes to it:

CREATE TABLE ACCOUNTABILITY (
OBJECTID number (22) NOT NULL,
OBJECTOWNERID decimal (22),
COMMISOID decimal (22),
RESPONOID decimal (22),
COMMISOBJECTTYPE CHARACTER (5),
RESPONOBJECTTYPE CHARACTER (5),
ACCOUNTYPEOID decimal (22),
BEGINDATE TIMESTAMP,
ENDDATE TIMESTAMP,
OBJECTTYPE CHARACTER (5),
ACL decimal (22),
REPLICNUMBER INTEGER,
ROWLASTCHANGE TIMESTAMP NOT NULL)
;

Any suggestions? I am all ears and eyes.

Zuf


"number" and "timestamp" are not valid Jet SQL datatypes. Click F1,
click the link to get you to the table of contents, scroll down to the
Jet SQL Reference node, expand it, then expand Overview and select the
Data Types topic. You'll find you should be using "decimal" and
"datetime" respectively.
 
B

Bob Barrows

zufie said:
I am trying to Create a table from DDL code.

Upon running the query I get the error: Syntax error in CREATE TABLE
statement. (Error 3290)

Here is my code after making many changes to it:

CREATE TABLE ACCOUNTABILITY (
OBJECTID number (22) NOT NULL,
OBJECTOWNERID decimal (22),
COMMISOID decimal (22),
RESPONOID decimal (22),
COMMISOBJECTTYPE CHARACTER (5),
RESPONOBJECTTYPE CHARACTER (5),
ACCOUNTYPEOID decimal (22),
BEGINDATE TIMESTAMP,
ENDDATE TIMESTAMP,
OBJECTTYPE CHARACTER (5),
ACL decimal (22),
REPLICNUMBER INTEGER,
ROWLASTCHANGE TIMESTAMP NOT NULL)
;

Any suggestions? I am all ears and eyes.

Zuf


"number" and "timestamp" are not valid Jet SQL datatypes. Click F1,
click the link to get you to the table of contents, scroll down to the
Jet SQL Reference node, expand it, then expand Overview and select the
Data Types topic. You'll find you should be using "decimal" and
"datetime" respectively.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top