ACC: Setting DAO Required Property Against SQL Server Fails Silently (200407)
The information in this article applies to:
- Microsoft Access 2.0
- Microsoft Access for Windows 95 7.0
- Microsoft Access 97
This article was previously published under Q200407 Advanced: Requires expert coding, interoperability, and multiuser
skills.
SYMPTOMS When you use Data Access Objects (DAO) to set the Required property of a field in a SQL Server table, the attempt fails
silently. RESOLUTION Instead of using DAO, execute Data Definition Language (DDL) statements from a SQL pass-through query to create a table
with columns that do not allow Null values. Note the following sample DDL statement, which
creates a table named tblTest with one field named F1. The F1 field does not
accept Null values:
CREATE TABLE "tblTest" ("F1" varchar(50) NOT NULL)
STATUSMicrosoft
has confirmed that this is a problem in the Microsoft products that are listed
at the beginning of this article.
REFERENCES For more information about creating pass-through queries in
Microsoft Access 97, type the following line in the Microsoft Office Assistant:
"Send commands to an SQL database using a pass-through query."
For
more information about creating pass-through queries in Microsoft Access 95,
type the following line the Microsoft Access 95 Answer Wizard: "Send commands
to an SQL database using a pass-through query."
For more information
about creating pass-through queries in Microsoft Access 2.0, Click Help, and then Search. Click the Index tab, and type "pass-through query."
Modification Type: | Minor | Last Reviewed: | 1/26/2005 |
---|
Keywords: | kbbug kbpending KB200407 |
---|
|