Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / Setup / April 2007

Tip: Looking for answers? Try searching our database.

How can I have SQL 2005 express or SQL prerequisite in a deploymen

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Morris Neuman - 05 Apr 2007 03:36 GMT
In VS .net 2005 I'm building an install package for a website that requires
SQL server or SQL express to operate.  In the deployment package's Project
properties I specified SQL 2005 express as a prerequisite in a bootstrap
deployment for the website.

The deployment works correctly if there is no SQL server on the target
machine and first installs SQL 2005 Express.  But on a system that is already
running SQL 2005 (not express but full version) the install package tries to
install SQL 2005 express.  Should SQL 2005 satisfy the SQL 2005 Express
prerequisite?  Or how can I specify that SQL 2005 or SQL 2005 Express both
satisfy the prerequisite?
Signature

Thanks
Morris

Steven Cheng[MSFT] - 05 Apr 2007 09:30 GMT
Hi Morris,

As for the SQL Express BootStrapper package, it simply install an SQL
Server express edition instance with the instance name as "SQLExpress" on
the target machine. Thus, no matter whether there is SQL Server Full
edition installed on the box or not, the SQL Express bootstrapper package
just check whether there is any existing SQL server 2005 instance with
instance name as "SQLEXPRESS" on the box, if not, it will install the SQL
Express instance.

For your scenario, if you want to do some other customized checking to
control the installation of SQLExpress bootstrapper package, you can
consider add some custom "install check" logic. You can refer to the
following MSDN article for detailed info:

#Authoring a Custom Bootstrapper Package for Visual Studio 2005
http://msdn2.microsoft.com/en-us/library/aa730839(VS.80).aspx

Also, all those existing VS 2005 setup bootstrapper packages are under the
following location(include the SQLExpress ):

C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\BootStrapper\Packages

You can simply find the SQL Express one and customize it(the xml configure
file ot if)  or copy it and build a new bootstrapper package based on it.

Hope this helps.  If you have any other questions on this, please feel free
to post here.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead



==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.



Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.

==================================================



This posting is provided "AS IS" with no warranties, and confers no rights.
Morris Neuman - 05 Apr 2007 22:10 GMT
Thanks for that info.  

Can you tell me just what I need to add to test for an SQL server installed
on the target system?

That atricle is helpfull but Is there a reference for all the elements and
attributes in the Product.xml and package.xml? and what about all the product
codes at least for Microsoft products?  Without this info the article is just
interesting info but not useful.

What about SqlExpressChk.exe what does that do and return?  Are there other
Chk.exe programs that check for other programs?

Signature

Thanks
Morris

> Hi Morris,
>
[quoted text clipped - 58 lines]
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
Steven Cheng[MSFT] - 06 Apr 2007 10:37 GMT
Thanks for your reply Morris,

For checking whether the bootstrapper package has already been installed,
the xml package file provide the <InstallChecks> setting(also mentioned in
the previous article I mentioned), you have several choice of property
source, such as "msiProductInfo", "registry info", "file path info"  or use
custom exe program to do the check:

#<InstallChecks> Element (ClickOnce Bootstrapper)
http://msdn2.microsoft.com/ru-ru/library/ms229432(VS.80).aspx

The SQLExpress built-in bootstrapper use a custom exe "SqlExpressChk.exe"
to do the checking. I'm not sure on its exact code, but I think it could
use the windows registry or WMI interface to checking the SQL Express
installation info.

For windows registry, you can simply check the following registry key since
it is exsting after you installed the SQL Express instance:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\SQLEXPRESS

There is also a blog article introducing a WMI approach for detecting SQL
2005 instance since registry means is not quite documented which may vary
from different version:

#FAQ: Detecting SQL Server 2005 using WMI
http://blogs.msdn.com/sqlexpress/archive/2006/07/29/682254.aspx

Hope this helps further.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

This posting is provided "AS IS" with no warranties, and confers no rights.
Steven Cheng[MSFT] - 10 Apr 2007 15:25 GMT
Hi Morris,

Does the information in my last reply helps some? If you have any further
questions, please feel free to let me know.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead


This posting is provided "AS IS" with no warranties, and confers no rights.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.