Embedding SQL server express 2005 with my applicat

2019-04-16 01:48发布

问题:

How can I embed Sql server 2005 express edition with my Setup package as one file?

Thanks.

P.S:It's a Windows Application.

回答1:

See http://msdn.microsoft.com/en-us/library/bb264562.aspx for embedding instructions.

Don't let the "Using a Wrapper" section intimidate...You won't need that. But you will need the command line switches. The installer is a single executable that can be fired off from your main installer, and the command line switches provide all of the control you will need for a successful installation.

See also here:

Configuring SQL Express During Installation http://blogs.msdn.com/sqlexpress/archive/2006/09/20/763956.aspx.



回答2:

Well technically, to really embed a database, you'd have to use something like SqlCe, SQLite, etc. SQL Express still runs as a service, so I don't know if you can really embed it.