Click here to Skip to main content
15,885,881 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more: , +
i developed application in visual c# which use sql server 2008 to store and retrieve data when i deploy this application to friend PC.
1)because of absolute link i am getting error to connect to the database
2)i need to install sql server and restore database on that pc
is there any way to automate this like searching database and connect it so that my first problem will solve and also automatically install required sql server component instead of whole installation of sql server.
feel free to asked more specific details if required.
Posted
Comments
[no name] 27-Jun-15 11:23am    
Since you are going to repost this over and over....
Read the documentation for whatever you are using to create your install package. That will tell you what you need to do to accomplish this. We can't read your mind either.
F-ES Sitecore 27-Jun-15 13:07pm    
SQL Server isn't a distributable component, it's a standalone product. You don't give SQL Server away with your app, the target machine either needs SQL installed or you need your database on a server that the client can attach to. It might be better to use SQL Compact as that is intended to be distributable.

For install makers try Install Shield. If you're only interested in free products then you should mention that in your question, and you'll find suggestions if you google.
Suvendu Shekhar Giri 27-Jun-15 18:34pm    
Perfect suggestion :)

1 solution

Instead of installing and setting up the entire SQL database in the machine where you are deploying the application, why cant you use the App_Data folder of your solution for the Sql MDF file storage and then use that MDF file for application.
If will not require the SQL server on the machine where you are deploying the Application, though will require the SQL adapters installed.
 
Share this answer
 
Comments
Member 11012743 28-Jun-15 2:49am    
thanks i will try that
Member 11012743 28-Jun-15 8:52am    
adityasahver can you guide me for that what you suggested
adityasahver 28-Jun-15 13:10pm    
http://www.codeproject.com/Questions/441590/How-to-add-existing-database-in-app-data-folder-in

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900