sql_language thread: Set Default Value In Access 2000 using SQL ALTER COLUMN command.
Alter MyTable Add Default 'Hi' For MyColumn
-----Original Message-----
From: David Savage [mailto:dave@t...]
Sent: Thursday, December 20, 2001 2:21 PM
To: sql language
Subject: [sql_language] Set Default Value In Access 2000 using SQL ALTER
COLUMN command.
I am having problems setting a default value for a column in an Access
2000 database using a SQL string within an ASP command.
My SQL string is:
rSQL ="ALTER TABLE TableName ALTER COLUMN ColumnName SET DEFAULT 'hello'"
this should work according to Microsoft and works fine with mySQL, but I
keep getting the following error message:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[Microsoft][ODBC Microsoft Access Driver] Syntax error in ALTER TABLE
statement.
Anyone have any idea what I'm doing wrong?
Many Thanks
Dave Savage
$subst('Email.Unsub').
This electronic message transmission, including any attachments, contains information from PacifiCare Health Systems Inc. which may
be confidential or privileged. The information is intended to be for the use of the individual or entity named above. If you are not
the intended recipient, be aware that any disclosure, copying, distribution or use of the contents of this information is
prohibited.
If you have received this electronic transmission in error, please notify the sender immediately by a "reply to sender only" message
and destroy all electronic and hard copies of the communication, including attachments.