Testing multiple DB connections - Advanced Installer Community
Ekki
Posts: 8
Joined: Thu Jun 27, 2013 11:26 am

Testing multiple DB connections

Hello.

I have asp.net web site which consumes data from two database.
Also, there are two connection strings in the web.config file: connectionString1 and connectionString2.
1) connectionString1 is a connection string to MS SQL Server.
2) connectionString2 may be connection string to the one of three DB - MSSQL, MySQL or Oracle. I have three connectionString2 templates for each of these DB.

For creating and testing connection 1 I'm using SQLConnectionDlg dialog with predefined SQL Server driver.
For creating and testing connection 2 I cannot use same SQLConnectionDlg dialog (it is possible create only one of them).

What is the best approach to create and test connection 2?

I think, I can create new dialog which looks like SQLConnectionDlg. But in this case user must type "ODBC Resource" manualy. Is it possible to use drop down list with existing ODBC drivers? And how I choose which connectionString2 template I must to use?
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Testing multiple DB connections

Hello and welcome to Advanced Installer forums,

Thank you for your interest in Advanced Installer.

In order to achieve this you can create multiple dialogs (similars with our predefined SQLConnectionDlg) as it is described in our "Multiple SqlConnections" thread. Then, you can conditionally show the new created dialogs.
But in this case user must type "ODBC Resource" manualy. Is it possible to use drop down list with existing ODBC drivers?
I'm afraid we don't have predefined support to browse for existing ODBC drivers. However, in order to achieve this you can create your own custom action to search for ODBC drivers on target machine and to populate a combo box control.
Also, you can use a default value for the related "ODBC Resource" controls.

If you have any questions let us know.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”