BUG: 16-bit ODBC Connections Fail on Large Databases

Last reviewed: March 26, 1996
Article ID: Q148888
The information in this article applies to:
  • Professional and Enterprise Editions of Microsoft Visual Basic, 16-bit only, for Windows, version 4.0

SYMPTOMS

A 16-bit Visual Basic program that attempts to connect to a large database fails and displays the error message, "Run-time error '3393.' Can't perform join, group or sort. Combined fields are too long."

STATUS

Microsoft has confirmed this to be an issue in the Microsoft products listed at the beginning of this article. Microsoft is researching this issue and will post new information here in the Microsoft Knowledge Base as it becomes available.

WORKAROUND

Use the following steps to work around this issue:

  1. Set the initialization path property of the DBEngine object to the VB.INI file and add the following entry to the VB.INI file:

          [ODBC]
    
             DisableAsync=1
    
    

  2. Place the following line in your code so the Initialization file is found by your application:

          DBEngine.IniPath = "c:\winnt35\vb.ini"
    

MORE INFORMATION

The following example to reproduce this issue assumes that you have established a connection to your ODBC database. Make the appropriate code changes in this example to connect to your database.

Steps to Reproduce Behavior

  1. Start 16-bit edition of Visual Basic 4.0, or if it is already running, click New Project on the File menu.

  2. Copy the following code to the Code window of the Form1 form:

          Option Explicit
    

          Private Sub Form_Load()
          Dim db As Database
          Dim rs As Recordset
    

          'Change the following two lines to connect to
          ' your ODBC database.
          Set db = OpenDatabase("", False, False, "odbc;")
          Set rs = db.OpenRecordset("select * from bugs")
          rs.MoveLast
    
          Debug.Print "The End"    'To show you the end of the program.
    
          End Sub
    
    

  3. On the Run menu, click Start or press the F5 key to start the program. After connecting to your ODBC database, the program displays the following error message:

          Run-time error '3393.'
          Can't perform join, group, or sort. Combined fields are too long.
    


KBCategory: kbprg kbbuglist
KBSubcategory: APrgDataOther
Additional reference words: 4.00 vb4win vb416 buglist4.00



THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: March 26, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.