PDA

View Full Version : SQL Server 2005 Express setup



Andufer
11-01-2006, 06:16 AM
Hi,
does anyone knows how to make an installation including the Setup prerequisite SQL Server 2005 Express and how to create a Setup.ini or include some parameters for installing SQL Serve in silent mode?
I'm using Installshield Express 12.0

bkeppler
11-01-2006, 09:49 AM
I have included the text from a SQL Server 2005 Express .prq file that installs SQL Server 2005 Express silently. Just use the XML provided below to create the following file:

<IS12 Express installation dir>\SetupPrerequisites\SQLServer2005Express.prq

----------------------------- cut here -----------------------------
<?xml version="1.0" encoding="utf-8"?>
<SetupPrereq>
<conditions>
<condition Type="16" Comparison="2" Path="[ProgramFilesFolder]Microsoft SQL Server\90\COM" FileName="sqlresld90.dll"
ReturnValue="2005.90.1399.0"/>
</conditions>
<files>
<file LocalFile="&lt;ISProductFolder&gt;\SetupPrerequisites\SQL2005Express\SQLEXPR.EXE"
CheckSum="6797955B505D3871CABB630DB28623A9" FileSize="0,56105688"/>
</files>
<execute file="SQLEXPR.EXE" cmdline=" /qb ADDLOCAL=SQL_Engine,SQL_Data_Files SECURITYMODE=SQL INSTANCENAME=MSSQLSERVER SAPWD=&quot;qm@ticc0rp&quot; DISABLENETWORKPROTOCOLS=2 SQLAUTOSTART=1"
requiresmsiengine="1"/>
<properties Id="Microsoft SQL Server 2005 Express"
Description="This installs Microsoft SQL Server 2005 Express Edition (SQL Server Express). The /qn switch suppresses all Setup dialog boxes and error messages. See http://msdn2.microsoft.com/en-us/library/ms144259.aspx for more information about the command line options."/>
</SetupPrereq>
----------------------------- cut here -----------------------------

Make sure you have the SQL Server 2005 Express installation package in the SQL2005Express subdirectory of the SetupPrerequisites folder. After the prerequisite is created just go into the Redistributables screen and select "Microsoft SQL Server 2005 Express".

I created this prerequisite by modifying the one I found at http://www.installsite.org/pages/en/msi/isd.htm which has a number of useful tidbits.

BTW, I also have a SQL Server Management Studio Express prerequisite if you need it. Just let me know.

Regards,

Ben Keppler
Software Developer
Q-MATIC Corporation

Andufer
11-02-2006, 02:16 PM
Thanks Ben,
I'll try your suggestions tomorrow.
Is the first time I develop an application using MS SQL. If you have experience, can you tell me what I need to do in order to register the database on the client computer and if the application need to do that and how to protect the database and register the user and password on the client computer?
If there's a document showing what I need, tell me the url.
Thanks a lot and regards.

bkeppler
11-07-2006, 09:43 AM
I just wanted to check and see if you got the private message I sent regarding initting the SQL Server Database. I'm not sure exactly how the private messages work. I can put a public post here with the info if you are unable to get it. I figured it was unrelated to IS12 Express which is why I sent the private message originally.

AndreasI
12-05-2006, 10:03 AM
The Script for the silent Setup works perfekt! Really good Post :-) Thank you!

Now there comes another problem: After the Distribution of my Application I get Error 26 if the Apllications tries to create a new User Instanz. It says that Remote Connections are not allowed or the Server/Instanze can not be found!

Anyone an Idea?

AndreasI
12-05-2006, 11:04 AM
.... I found the error, but I don´t know how to solve it! The Script is checking if MSSQLServer is installed... for my application it is needed to check if a spezial name of a instanze is installed... if not (for example: .\test") then the Setup should install this instanze. (Example: .\Test)

Does anyone have a sollution for that?

Thanks

bkeppler
12-05-2006, 12:11 PM
Unfortunately, that would require having more knowledge of the <condition> element's "type" and "comparison" attributes in the setup prerequisite (.prq) file. If there was any documentation on them, I think it would not be difficult to figure it out, but as far as I know, there is no public documentation on the prerequisite file's schema. :mad: Barring having the documentation, here is my stab at doing the check: Replace the existing condition in the prerequisite file for MSSQL to the following:

<condition Type="2" Comparison="2" Path="HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\InstanceNames\SQL" FileName="MY_INSTANCE_NAME" ReturnValue="MSSQL.1"/>

Then change the "cmdline" attribute of the <execute> element to contain

INSTANCENAME=MY_INSTANCE_NAME

rather than

INSTANCENAME=MSSQLSERVER

I have not tested this, but with a little playing around, it will might work.

AndreasI
12-05-2006, 11:43 PM
Here is the Code for the German Version of SQL Server 2005 Express... this Code checkes if a named instance is already installed and only installes if the named instanze doesn´t exist!

------------------------------------
<?xml version="1.0" encoding="utf-8"?>
<SetupPrereq>
<conditions>
<condition Type="1" Comparison="2" Path="HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names\SQL" FileName="myinstancename " ReturnValue=""/>
</conditions>
<files>
<file LocalFile="&lt;ISProductFolder&gt;\SetupPrerequisites\SQL2005Express\SQLEXPR_GER.EXE"
CheckSum="F6A111725E92D2BBCEFFF8C6EFD9A7FB" FileSize="0,61258528"/>
</files>
<execute file="SQLEXPR_GER.EXE" cmdline=" /qb ADDLOCAL=SQL_Engine,SQL_Data_Files SECURITYMODE=SQL INSTANCENAME=myinstancename SAPWD=&quot;qm@ticc0rp&quot; DISABLENETWORKPROTOCOLS=2 SQLAUTOSTART=1"
requiresmsiengine="1"/>
<properties Id="Microsoft SQL Server 2005 Express"
Description="This installs Microsoft SQL Server 2005 Express Edition SP1 German. The /qn switch suppresses all Setup dialog boxes and error messages. See http://msdn2.microsoft.com/en-us/library/ms144259.aspx for more information about the command line options."/>
</SetupPrereq>

----------------------
Note: Now I now why some developers buy the Profesional Edition!

Raju Sathliya
08-29-2007, 06:37 AM
Hi,
I am new to installShield. I want my sql server 2005 prerequisite to install in silence mode. I have tried as per your suggestion but still not getting to install SQL Server 2005 Express in silent mode its still install it in GUI mode.
These are the steps followed by me...
1) I have copy your given SQLServer2005Express.prq code and then open my IS Express installdir>\SetupPrerequisites\SQLServer2005Express.prq and past it in place of existing code.
2) From IA prerequisite list check on SQL Server 2005 option and create one exe which now include SQL Server 2005 Express prerequisite.
3) But It install this prerequisite in GUI mode not in silent mode.
So you have any suggestion for me, where I am going wrong??

-Thanks
Raju





I have included the text from a SQL Server 2005 Express .prq file that installs SQL Server 2005 Express silently. Just use the XML provided below to create the following file:

<IS12 Express installation dir>\SetupPrerequisites\SQLServer2005Express.prq

----------------------------- cut here -----------------------------
<?xml version="1.0" encoding="utf-8"?>
<SetupPrereq>
<conditions>
<condition Type="16" Comparison="2" Path="[ProgramFilesFolder]Microsoft SQL Server\90\COM" FileName="sqlresld90.dll"
ReturnValue="2005.90.1399.0"/>
</conditions>
<files>
<file LocalFile="&lt;ISProductFolder&gt;\SetupPrerequisites\SQL2005Express\SQLEXPR.EXE"
CheckSum="6797955B505D3871CABB630DB28623A9" FileSize="0,56105688"/>
</files>
<execute file="SQLEXPR.EXE" cmdline=" /qb ADDLOCAL=SQL_Engine,SQL_Data_Files SECURITYMODE=SQL INSTANCENAME=MSSQLSERVER SAPWD=&quot;qm@ticc0rp&quot; DISABLENETWORKPROTOCOLS=2 SQLAUTOSTART=1"
requiresmsiengine="1"/>
<properties Id="Microsoft SQL Server 2005 Express"
Description="This installs Microsoft SQL Server 2005 Express Edition (SQL Server Express). The /qn switch suppresses all Setup dialog boxes and error messages. See http://msdn2.microsoft.com/en-us/library/ms144259.aspx for more information about the command line options."/>
</SetupPrereq>
----------------------------- cut here -----------------------------

Make sure you have the SQL Server 2005 Express installation package in the SQL2005Express subdirectory of the SetupPrerequisites folder. After the prerequisite is created just go into the Redistributables screen and select "Microsoft SQL Server 2005 Express".

I created this prerequisite by modifying the one I found at http://www.installsite.org/pages/en/msi/isd.htm which has a number of useful tidbits.

BTW, I also have a SQL Server Management Studio Express prerequisite if you need it. Just let me know.

Regards,

Ben Keppler
Software Developer
Q-MATIC Corporation

Earthshine
11-06-2007, 11:56 AM
I have included the text from a SQL Server 2005 Express .prq file that installs SQL Server 2005 Express silently. Just use the XML provided below to create the following file:

<IS12 Express installation dir>\SetupPrerequisites\SQLServer2005Express.prq

----------------------------- cut here -----------------------------
<?xml version="1.0" encoding="utf-8"?>
<SetupPrereq>
<conditions>
<condition Type="16" Comparison="2" Path="[ProgramFilesFolder]Microsoft SQL Server\90\COM" FileName="sqlresld90.dll"
ReturnValue="2005.90.1399.0"/>
</conditions>
<files>
<file LocalFile="&lt;ISProductFolder&gt;\SetupPrerequisites\SQL2005Express\SQLEXPR.EXE"
CheckSum="6797955B505D3871CABB630DB28623A9" FileSize="0,56105688"/>
</files>
<execute file="SQLEXPR.EXE" cmdline=" /qb ADDLOCAL=SQL_Engine,SQL_Data_Files SECURITYMODE=SQL INSTANCENAME=MSSQLSERVER SAPWD=&quot;qm@ticc0rp&quot; DISABLENETWORKPROTOCOLS=2 SQLAUTOSTART=1"
requiresmsiengine="1"/>
<properties Id="Microsoft SQL Server 2005 Express"
Description="This installs Microsoft SQL Server 2005 Express Edition (SQL Server Express). The /qn switch suppresses all Setup dialog boxes and error messages. See http://msdn2.microsoft.com/en-us/library/ms144259.aspx for more information about the command line options."/>
</SetupPrereq>
----------------------------- cut here -----------------------------

Make sure you have the SQL Server 2005 Express installation package in the SQL2005Express subdirectory of the SetupPrerequisites folder. After the prerequisite is created just go into the Redistributables screen and select "Microsoft SQL Server 2005 Express".

I created this prerequisite by modifying the one I found at http://www.installsite.org/pages/en/msi/isd.htm which has a number of useful tidbits.

BTW, I also have a SQL Server Management Studio Express prerequisite if you need it. Just let me know.

Regards,

Ben Keppler
Software Developer
Q-MATIC Corporation

I would LOVE to have your prereq for the management tool. Also, I have never created a prereq. Is it difficult? I am trying to do it but not having much luck. n00b's, go figure. LOL

Thank you for any help.

anil.bly
01-28-2010, 06:14 PM
Hi

Currenlty I am using InstallShield 2008 professional edition. I am also trying to install sql express2005 (sqlexpr32.exe) in slient mode.Now sql express is installing successfully but it does not enabled the remote connection.

I am using below command line argument for enabling the remote connection :

SecurityMode=SQL
disablednetowrkprotocals=1
sqlbrowserautostart=1
sqlautostart=1

Using above arguments,i am able to install properly with remote connection enabled (tcp and named pipe both) from command promt. But failed when trying with InstallShield .

Please help me on that, How can i install sql express in slient mode with remote connection so that any remote system can also access it.



I Have also tried "2" for diablednetowrkprotocal

Nirmal
06-28-2011, 02:25 AM
Hi,
I need to know what this code exactly do..
What does exactly the condtion type and comparision do?


<?xml version="1.0" encoding="UTF-8"?>
<SetupPrereq>
<operatingsystemconditions>
<operatingsystemcondition PlatformId="2" CSDVersion=""></operatingsystemcondition>
</operatingsystemconditions>
<conditions>
<condition Type="2" Comparison="2" Path="HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Web Start" FileName="CurrentVersion" ReturnValue="1.6.0_21"></condition>
</conditions>
<files>
<file LocalFile="&lt;PATH_TO_3RDPARTY_PREREQ&gt;\jre-6u21-windows-i586-s.exe" FileSize="0,0"></file>
</files>
<execute file="jre-6u21-windows-i586-s.exe" cmdline="/s /qn /norestart" cmdlinesilent="/s /qn /norestart" requiresmsiengine="1"></execute>
<properties Id="Java 2 Standard Edition Runtime Environment 6 Update 21" Description="This installs the Java 2 Platform Standard Edition Runtime Environment 6.0 Update 21. This installation will run on Windows 2000 (SP3), Windows XP (Home and Professional), and Windows 2003 Server."></properties>
<behavior Hidden="1"></behavior>
</SetupPrereq>