Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2003
    Posts
    107

    Unanswered: deploying windows app and a sql server express database

    Hi there. I've created a windows forms app that connects to a sql server express database. now that it's working on my box, i need to install the entire solution on the end user's machine.
    what's the best way to move the database? I found this article:
    http://msdn.microsoft.com/en-us/library/ms165716.aspx
    but i'm wondering if anyone can give me some insights based on your own experience.
    I'm using ms visual studio 2005 and sql server express 2005.
    I'm hoping that all i'll really have to do is copy everything over to the new machine and then edit my connection string in the .exe.config file for my app.

    Thanks in advance for your help.

  2. #2
    Join Date
    Jul 2003
    Location
    San Antonio, TX
    Posts
    3,662
    The right way (not to be confused with the easy way) is to create an install program, that deploys your app, along with conditional deployment of SQLExpress. Ideally the connection string needs to be built at the time of user logging into your app, but you can also "scatter" it in the registry (not a clean way). But if for every new client you have to modify a connection string and then recompile the app, - you'll run out of steam pretty quick, especially if in all other respects your app satisfies the customer.
    "The data in a record depends on the Key to the record, the Whole Key, and
    nothing but the Key, so help me Codd."

  3. #3
    Join Date
    Feb 2003
    Posts
    107

    install program...

    if I play around with the install wizard, is it possible for me to mess things up on my dev environment? Just want to be safe...before i begin playing around.
    thank you for the help.

  4. #4
    Join Date
    Jul 2003
    Location
    San Antonio, TX
    Posts
    3,662
    No it is not, because you will overwrite your dev and lose the source. You need to set up a test target, and play around against that.
    "The data in a record depends on the Key to the record, the Whole Key, and
    nothing but the Key, so help me Codd."

  5. #5
    Join Date
    Feb 2003
    Posts
    107
    I've used the Publish page in my project properties to create a set up program. And I included SQL Server Express, as well as the Windows Installer 3.1 required by SQL. It published to my ftp site no problems.. but how do i know if it packaged up my database / data in addition to the SQL Server Express Engine?
    Or is it not supposed to do that? Should I be now looking into how to package up my database separately?

  6. #6
    Join Date
    Jul 2003
    Location
    San Antonio, TX
    Posts
    3,662
    You also need to include .NET 2.0, because it does not come with SQLExpress, and in the installer sequence ensure that you're deploying it first before attempting to install SQLExpress.
    "The data in a record depends on the Key to the record, the Whole Key, and
    nothing but the Key, so help me Codd."

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •