ACC2000: Error Message: "ADO error: Line 1 : Incorrect Syntax Near '\'." When You Try to Save a View (264950)



The information in this article applies to:

  • Microsoft Access 2000

This article was previously published under Q264950
Moderate: Requires basic macro, coding, and interoperability skills.

This article applies only to a Microsoft Access project (.adp).

SYMPTOMS

In an Access project, you create a view, but when you try to save it, you receive the following error message:
ADO error: Line 1 : Incorrect syntax near '\'.

CAUSE

Your logon is not a member of the db_owner group.

RESOLUTION

To prevent this error message and to allow you to save the view, do one of the following:
  • Add the logon to the db_owners group.
  • Change the project's Connection to a user who is already a member of the db_owners group.
  • Instead of a view, create a stored procedure that contains a select statement, and then view it in Datasheet view.

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.

MORE INFORMATION

Steps to Reproduce the Behavior

  1. Create a new project to the Microsoft Data Engine (MSDE) or to the Microsoft SQL Server 7.0 sample database NorthwindCS.adp.
  2. Create a new user who is not a member of the db_owner group. To do so, follow these steps:
    1. On the Tools menu, point to Security, and then click Database Security. The SQL Server Security dialog box appears.
    2. On the Server Logins tab, click Add.
    3. In the SQL Server Login Properties window, enter a new user name.
    4. Click SQL Server authentication, leaving the password blank, and then click Northwind in the default database list.
    5. Click the Database Access tab, and then click to select the Permit check box to assign permissions to Northwind. Leave the default Public role selected.
    6. Click OK twice to close the SQL Server security dialog boxes.
  3. On the File menu, click Connection.
  4. Verify that Use a specific user name and password is selected, and then enter the user name that you just created. Click OK to close the dialog box. This resets the connection of the project to the new user.

    NOTE: When the new user is active, the table name listing will include (dbo) after each table name.
  5. Click Views, and then create a new one. Add all the fields from the Categories table.
  6. Try to save the new view. Note that you receive the error mentioned in the "Symptoms" section of this article.

Modification Type:MinorLast Reviewed:1/26/2005
Keywords:kbbug kberrmsg kbnofix KB264950