Click here to Skip to main content
15,892,289 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have desktop application that created in vs 2015 and back end use sql server 2014 .
i have 50 client with window 7 and i have no option for install sql server in client pc so how to run exe with database operation

What I have tried:

Hello I have tried to attached database as resource but and many time searches in google but dont find any idea.
Posted
Updated 27-Sep-17 0:17am

1 solution

You don't.
One instance of SQL Server is installed on the client network, and they all connect to that. If you start installing SQL server instances, then it all gets horribly messy:

0) You can only distribute SQL Server Express for copyright reasons - not SQL Server full version.
1) They may already have SQL Server installed on the network. If so, then they will presumably want to use that version.
2) If they do have SQL server installed and you start proliferating SQL server Express instances, you are going to annoy the heck out of the database administrator...
3) A single site installation of SQl Server is a lot more likely to be backed up than a number of scattered version under user control.
4) Sql server is quite complex for a "normal" user to install and administer - it is not a good idea!
5) It will destroy the primary advantage of using Sql Server over SqlCE or SQLite - multiuser access. If everyone installs their own copy of SQL server, then you will have multiple copies of your database, each used by a single person. This will cause some confusion, and (depending on how you wrote the original database) may take some considerable effort to combine into a single instance when the problem is realized.

So talk to the client and see if they already have SQL server, if so, you will need to add your DB to that, and probably arrange a suitable SQL User to access it - their DB admin should be able to help there.

Then all you need is to set the connection string that your app uses correctly, and all clients connect to the same database. If your code is designed correctly, the string will be in an external configuration file, so it's not a problem to change without having to recompile you program.
 
Share this answer
 
Comments
chintan710 2-Oct-17 7:56am    
Thanks for your solution..
OriginalGriff 2-Oct-17 8:21am    
You're welcome!

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