cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
rfitzpat
Level 4

ISSQLServerValidate checks Database Server requirements even if feature is turned off

I would desire one install that can install a database for either MS SQL Server or for Oracle Server along with a Web Server.
I am using InstallShield 2012 (Basic MSI Project)

In the SQL Scripts view I have two SQL Connections, one for MS SQL and one for Oracle.
These connections have requirements, Microsoft SQL Server for the MS SQL one and Oracle for the Oracle connection.
I only need the requirements meet for the connection that is part of the active feature.
It seems the SqlScript is linked to the feature not the database connection.

It appears...."By default, all the connections in the ISSQLConnection table will be validated."
I do not want all connections validated.
If the user selects the MS SQL option, that is the connection that will be used.
If the user selects the Oracle option, then check for Oracle driver.

The user's machine will have either MS SQL or Oracle, not necessarily both.

Each of these connections and sql scripts are part of their own feature.
I have added a custom dialog to allow the user to choose between database types [MS SQL or Oracle](exclusive).
I am using remove and addlocal events on the next button to turn on/off the features.
It appears InstallShield is turning off the one feature and leaving the one the user selected on. Good.(off Oracle feature, leave on MS SQL feature)
I am checking this by calling the Custom Setup dialog box that displays features in a tree.
I have even added a DoAction, ISSQLServerCosting to the next button to make sure the install knows which feature to run and which to skip.

But after the user enters the information to the SQLLogin dialog box, the install try’s to validate both connections, since this machine only has MS SQL, the Oracle driver check fails.

Is there a method to have InstallShield only validate the only connection needed?
When I turn off one feature, why is the Oracle requirement still required?
Do I need to make two separate installs? one for MS SQL and one for Oracle?

Robert
Labels (1)
0 Kudos
(3) Replies
vyuschuk
Level 2

Try adding a ControlEvent that sets [IS_SQLSERVER_CONNECTIONS_TO_VALIDATE] to the connections you want validated.
0 Kudos
rfitzpat
Level 4

vyuschuk,
Thanks for the suggestions.
I did add two custom actions to set IS_SQLSERVER_CONNECTIONS_TO_VALIDATE, one for MSSQL and another for Oracle.
(There is not an InstallShield property of 'IS_SQLSERVER_CONNECTIONS_TO_VALIDATE')
I added Doactions to the Next button of the choose database dialog.
If user chose MSSQL, it would set IS_SQLSERVER_CONNECTIONS_TO_VALIDATE to the MSSQL connection to validate.
The install runs through to the end without complaining that there is no Oracle, on a MSSQL machine, but I see many error lines in the MSI log file.
So I am giving up and going with two separate installers.
One for MS SQL machines and one for Oracle machines.
In the end the installers will be cleaner and smaller since the one installer would not have both databases in the cab file.
Robert
0 Kudos
vyuschuk
Level 2

You could probably figure out how to get IS_SQLSERVER_CONNECTIONS_TO_VALIDATE to work as desired, but I can tell you that having two separate installers might have been better for me (for other reasons) so that sounds like a reasonable design choice. Good luck!
0 Kudos