Conditional SQL script Execution

Got a problem you cannot solve? Try here.
Post Reply
prezmer
Posts: 31
Joined: Wed Jul 23, 2008 8:59 am
Location: Warsaw, Poland

Conditional SQL script Execution

Post by prezmer »

Hello,

Is it possible to to execute SQL scripts conditionally? I would like to have a setup with 2 different installation modes. User decides using radio box which mode to use. In case of DB based mode, SQL scripts should be executed

best regards
Piotr Rezmer
bokkie
Posts: 767
Joined: Sun Feb 08, 2009 6:30 am

Post by bokkie »

Piotr, you have partially answered the question already. If you are linking your choice to radio buttons then you can check the status of the one selected and in that piece of code take whatever action is appropriate to your needs. How to execute the SQL is another thing. If you are using SQL Server you can feed a script into the osql.exe command. I think IA has something builtin that can do SQL related tasks but I've never used them. So, in short, it's possible to determine what you want to do.
Peter. Smartly dressed, he still resembles an unmade bed.
InstallAware MVP
Post Reply