0

Was just wondering if anyone here is an Access master

have this code that I want too add a CHECK too but keeps on throwing a syntax error

CREATE TABLE Email (
userEmailAddress memo not null, 
timeDate datetime not null,
contactEmailAddress memo not null,
emailBoxType text(6) not null,
readStatus binary(1) not null,
subject text(255),
message memo, 
primary key(userEmailAddress, timeDate),
)

and this is the check

CHECK (readStatus 'Y' 'N')

have tried all sorts of combination's but just can't get it to work, have googled and copied exactly how they use it but still just throws a syntax error.

Any help greatly appreciated.

2
Contributors
2
Replies
3
Views
8 Years
Discussion Span
Last Post by mr_scooby
0

CHECK constraint is not available in the CREATE TABLE statement for Access 2007 database.

Instead, you can define validation rule using Design View.

0

yeah did some further reading and couldn't find anything, so installed an app that reads the tables and exports the sql and you have to do it via ALTER TABLE

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.