PDA

View Full Version : SQL script order over multiple connections



ShaneJennings
12-18-2014, 11:35 AM
I'm currently evaluating InstallShield 2014 Premier and I am trying to create a basic MSI project. As part of the installation I need to run a number of SQL scripts over a number of different connections. I've read that scripts are executed in the order they are shown in InstallShield, however I cannot find any information about how to order scripts over multiple connections. I've read about batch mode, however it seems this is only for InstallScript projects.
As an example, I want to execute the following:
Script 1 on Database A
Script 2 on Database B
Script 3 on Database A
Script 3 on Database B
Script 4 on Database A
...
etc.

Am I missing something, or is this not possibly without duplicating connections?

hidenori
12-18-2014, 05:43 PM
Connections in Basc MSI projects are also processed in the order they are shown in the SQL Scripts view. If you have such a configuration below in the SQL Scripts view, InstallShield executes in the sequence of Script 4, and Script 3 against the Connection A, and then Script 2, and Script 1 against the Connection B.

Connection A
- Script 4
- Script 3
Connection B
- Script 2
- Script 1

In order to accomplish your requirement, you would need to have duplicate connections to execute your SQL scripts in the desired sequence.

Hope that helps.