cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Crackpot
Level 3

SQLBrowse2 and SQLRTGetServers2 display random servers

Hello,

we are encountering difficulties with the functions "SQLBrowse2" and "SQLRTGetServers2". We want to display a number of available database servers in our network and at first everything seemed ok. Both functions detected some servers but on closer examination we found out that the list of available servers seems to be absolutely random! On the first attempt we get 10 servers, on the second attempt only 3 and on the third attempt 5. There seems to be no regularity as to which servers are shown and which servers are skipped.
I tried to change the driver to native, but then I don't get a single server...
We are kind of helpless at this point because we tried nearly everything and I also searched this forum but didn't find a solution.

Any advice would be great!

Best regards
Labels (1)
0 Kudos
(5) Replies
hidenori
Level 17

Have you tried changing InstallShield use the Microsoft SQL Server Native Client driver as follows, and see if the behavior is changed?

[LIST=1]
  • Go to the ISSQLDBMetaData table in the Direct Editor.
  • Find the "MSSQLServer" row.
  • Change the AdoDriverName column from "sqlolddb" to "sqlncli".
  • Change the DsnODBCName column from "{SQL Server}" to "{SQL Native Client}"
  • Rebuild your setup


    Make sure that you have the SQL Native Client driver installed on your target machine.
  • 0 Kudos
    Crackpot
    Level 3

    We can't guarantee that on the target machines the native client is installed...
    0 Kudos
    hidenori
    Level 17

    InstallShield retrieves the list of Microsoft SQL Servers using an ODBC driver (SQL Server driver by default), and we have no control over the behavior that you are experiencing. If the SQL Native Client driver resolves the issue, you may want to consider adding the SQL Native Client prerequisite to your setup.
    0 Kudos
    Crackpot
    Level 3

    The problem is, we need this functionality prior to the installation process. We ask the user to specify on which Server the application should be installed and therefor we use the SQLBrowse function. So we would have to install the native drivers before we call the dialogues for the user.
    Nevertheless I tried the native driver and it works pretty well. And now? Damn it... :rolleyes:
    0 Kudos
    hidenori
    Level 17

    Setup prerequisites will be installed before the OnFirstUIBefore event. So it should be fine.
    0 Kudos