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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Alter Table Constraint Not Null (what is exact method for this?)

Status
Not open for further replies.

mflancour

MIS
Apr 23, 2002
379
US
This is how I tried to write it, but error occures.

MyDB.Execute "ALTER TABLE month ADD CONSTRAINT stuff NOT NULL ([f1])"
 
Hi mflancour,

I don't think you can alter it as a constraint.

The syntax, I think is ALTER TABLE TableName ALTER COLUMN ColumnName DataType NOT NULL

.. and it is not available prior to 2K.

I think you have to specify the data type even if you are not changing it.

Enjoy,
Tony

------------------------------------------------------------------------------------------------------
We want to help you; help us to do it by reading FAQ222-2244 before you ask a question.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top