amf
Posts: 10
Joined: Fri Aug 28, 2009 7:04 pm

SQL Scripts with conditions

Would like the ability to be able to set a condition on when a SQL script should be run. In other words, if I want the MSI to skip one of my SQL Scripts because the user checks a checkbox in a dialog page, that would be most useful (and likely pretty simple to implement). Would also make it easier to let the user select which type of database they are talking with (my application will soon talk to SQL Server, Oracle, or mySQL, and the SQL between the different systems is different enough that I want to be able to select which script will run based on the selected database server type.

Thanks!
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: SQL Scripts with conditions

Hi,
Would like the ability to be able to set a condition on when a SQL script should be run.
This can be done by using the SQL Script pane in the "SQL Scripts" page. You can set the "Script Condition" field to the condition you need.
Would also make it easier to let the user select which type of database they are talking with
For this you can try using this approach:
- configure the connections from the start
- condition their SQL scripts according to the user selection

During install, only the connections which have scripts with a true condition will be created.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Feature Requests”