Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

check constraint sql syntax help 1

Status
Not open for further replies.

h0gg1e

Programmer
Apr 8, 2004
15
US
I'm trying to create a simple check contraint in access without going into access's table designer.

basically in sql server 2000 I would do this ....

CREATE TABLE tblCHECKtest
(
item_code char(4)
CONSTRAINT CK_tblCHECKtest CHECK (item_code = '0000')
)

how can I do the above in access via a sql command ... it keeps returning 'Syntax error in CONSTRAINT clause'

thanks for any help
 
JetSQL doesn't admit CHECK in the CONSTRAINT clause.
Browse your computer local drives for files named JET*.CHM

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
PH - A star for that useful tip for finding the Jet Reference.

 
thanks for the insight ... you would think there would be a way to do that, but there isn't .. thanks again.
 
To be fair, there is a way. Go into the Table Design Dialogue. Not pure, but - heh - this is Microsoft...

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top