BUG: AV in MSADCE When Executing a SHAPE Query Using a .udl File

ID: Q208210


The information in this article applies to:


SYMPTOMS

The following procedure will result in an Access Violation in Msadce.dll (version 2.10.3513.2):

  1. Use the MSDataShape OLEDB Provider to create a .udl file.


  2. Connect to ADO 2.1 from MDAC 2.1, using client-side cursors.


  3. Issue a SHAPE query.



CAUSE

ADO is not able to recognize that you are using the Shape Provider because the connection string contains a reference to a .udl file instead of a reference to the Shape Provider.


RESOLUTION

To work around this problem do either of the following:


STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article.


MORE INFORMATION

Steps to Reproduce Behavior:

  1. Create a .udl file using Microsoft Data Links. To do so, right-click on the Windows desktop, point to New, and select Microsoft Data Link. Use the MSDataShape Provider and reference a DSN pointing to the Pubs database in SQL Server.


  2. Create a blank Visual Basic standard exe project, insert a command button into form1, and add the following code to the Click Event:
    
          Dim cnn As New ADODB.Connection
          Dim rst As New ADODB.Recordset
          Dim rsChapter As Recordset 'Variant
          cnn.CursorLocation = adUseClient
          cnn.Open "File Name=c:\data sources\pubs.udl"
          rst.Open "SHAPE  {select * from authors}APPEND ({select * from titleauthor} AS chapter RELATE au_id TO au_id)", cnn 


Additional query words: kbDSupport


Keywords          : 
Version           : WINDOWS:2.1
Platform          : WINDOWS 
Issue type        : kbbug 

Last Reviewed: May 11, 1999