PRB: Unable to Set Default Property of Column Object Using ADOX (255997)
The information in this article applies to:
- ActiveX Data Objects (ADO) 2.5
- ActiveX Data Objects (ADO) 2.6
- Microsoft OLE DB Provider for Jet 4.0
- Microsoft Visual Basic Learning Edition for Windows 6.0
- Microsoft Visual Basic Professional Edition for Windows 6.0
- Microsoft Visual Basic Enterprise Edition for Windows 6.0
This article was previously published under Q255997 SYMPTOMS
When attempting to set the Default property of an ADOX column object using the Microsoft Jet 4.0 provider, the value is not set. No error message is generated. Trying to change the Default property removes any existing Default value already in place.
RESOLUTION
To work around this problem, you can execute an ALTER TABLE command to accomplish the same functionality. For example, to add a default value to MyColumn in MyTable, use the following command:
ALTER TABLE MyTable ALTER COLUMN MyColumn SET DEFAULT 'DefaultValue'
STATUS
Microsoft is researching this issue and will post new information here in the Microsoft Knowledge Base as it becomes available. This problem was corrected in Jet 4.0 Service Pack 5.
For additional information about how to obtain the latest Jet 4.0 service pack, click the following article number to view the article in the Microsoft Knowledge Base:
239114
How To: Obtain the Latest Service Pack for the Microsoft Jet 4.0 Database Engine
Modification Type: | Minor | Last Reviewed: | 11/25/2003 |
---|
Keywords: | kbBug kbprb KB255997 |
---|
|