PRB: Table Names Using Quoted Identifiers Do Not Open Properly
ID: Q194010
 
  | 
The information in this article applies to:
- 
Microsoft Visual InterDev, version  6.0
 
- 
Microsoft SQL Server, Enterprise Edition, version  6.5
 
SYMPTOMS
When you open, or design against, existing tables in the Visual InterDev
Data View, one of the following error occurs:
-Table 'tablename' no longer exists in the database.
-[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax
   near 'tablename'.
-Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
   [Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax
   near '<tablename with space>'.
   /<project>/_ScriptLibrary/Recordset.ASP, line 466
CAUSE
This occurs when you attempt to view or open a table with a space in its
name in Design View, or if the "Use ANSI quoted identifiers" option is not
selected when you create the data connection to the database.
RESOLUTION
To avoid this problem, you can use one of the following workarounds:
- Delete the existing data connection from the project.
 
- Ensure that the option "Use ANSI quoted identifier" is selected in the
   Add data connection wizard, and then add a new Data Connection to the
   database.
 
-or-
- Recreate the table with a valid SQL Server name (no spaces).
 
STATUS
This behavior is by design.
MORE INFORMATION
Steps to Reproduce Behavior
- Create a new Database Project.
 
- Add a new SQL Server data connection. Make sure that the option "Use
   ANSI quoted identifiers" is not selected. You can find this option in
   the Add Data Connection wizard, on the pane that has the option "Change
   the Default Database to:".
 
- In the Data View tab of Visual InterDev, locate or create a table with a
   space in its name.
 
- Right-click on the table and click Design or Open.
 
-or-
- Create a new non-database project and add an ASP page, or add an ASP
   page to an existing non-database project.
 
- Drag a recordset Design-Time control (DTC) to the <BODY> portion of the
   page. Right-click on the DTC and click Properties. Set the Connection to
   the DSN where the option "Use ANSI quoted identifiers" is not selected.
 
- Set the Database Object to TABLES, and set the Object Name to the name
   of the table that contains a space.
 
- Save the page and use the View in Browser feature. The following error
   appears:
      Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
      [Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect
      syntax near '<tablename with space>'.
      /<project>/_ScriptLibrary/Recordset.ASP, line 466 
 
Additional query words: 
Keywords          : kberrmsg kbCtrl kbEEdition kbide kbSQLServ kbVisID600 kbGrpASP 
Version           : WINDOWS:6.0; winnt:6.5
Platform          : WINDOWS winnt 
Issue type        : kbprb