View Full Version : Installing SQL 2005 Express (not as a prerequisite) Urgent

12-03-2008, 06:48 AM

The setup I am working on right now needs to create a database, and the user can choose to either use an existing SQL Instance, or to install a new SQL Express edition Instance.

Option two is what is giving me problems, as I can't use the "add prerequisite" option. I mean, there is no need to tell the user that SQL is a prerequisite, if he plans to use his own sql server.

Installing SQL also requires me to check for dot net 2.0, again, only if the user chooses setup type 'B'. Setup type 'A' has nothing to do with the install of dot net, so I can't use the release wizard to add dot net, neither the prerequisite editor feature.

Trying to add .Net to the package as a custom action to the Execute Sequence made me realize it's not possible. I know dot net comes as a vendor .msi, so I tried to run it both before install initialize or after install finalize. Still, I get the message "Another installation in progress". I made it work by running it on the User Interface Sequence.

Same solution does not work for SQL Server though. If I try to run it in the User Interface Sequence, sql setup fails at installing "SQL server native client", with an error saying something like he can't find the "sql_native_client.msi". Error is misleading, it's issue is actually with the UI sequence.
If I try to run SQL setup as a custom action from the Execute Sequence, I don't get the error about the native client anymore, but later in the setup I get the "another installation already in progress" error, doesn't matter what's it's position in the sequence.

I'm running out of sequences :)

So please, can anyone tell me how to installl SQL Express as a custom action?
My customer wants it done in Install Shield 2008, upgrading to Install Shield 2009 is not an option.

Thank you very much for your help, this is also unfortunately very urgent.


12-03-2008, 11:57 AM
If you are using a project type that allows Install Shield script, then here are a couple of links you might be interested in.

ADO Example...

Search and Replace information in SQL Files...

Your situation that you are describing sounds very similar to what I have already achieved. This is what I'm able to do.

1) Create a new database.
2) Connect to an Exiting database.
3) Create database user with password.
4) Connect to local and/or remote database engine to any named instance.
5) Connect to a existing database defined in SQL Server and add tables and data to it.
6) Display a progress bar showing the progress of database creation and data updates.
7) Create databases on remote and/or local machines.

Everything mentioned above is done by using SQL scripts and ADO objects. Upon installation, I modify the SQL Script files based on the information I gather from the user. Thus, customizing the database installation to their needs and their requirements.

If you need more information, please let me know.

12-04-2008, 02:52 AM
Hi, thanks for your reply, but that's not even close to my issue.
I didn't even got to the part of running the necessary sql scripts.

My issue is how to install SQL Server 2005 from my setup, without using the add prerequisite feature. Ignore the database creation, or any other part.

An thread with the same issue:

Anyone else got a solution, workaround, ideas, anything? Please