I have made an application project in Visual Studio 2008 C#, SQL Server from Visual Studio 2008.
The database has like 20 tables and many fields in each.
I have made an interface for adding deleting editing and retrieving data according to predefined needs of the users.
Now I have to
-
Make to project into software which I can deliver to my professor. That is, he can just double click the icon and the software simply starts. No Visual Studio 2008 needed to start the debugging.
-
The database will be on one powerful computer (dual core latest everything Windows XP) and the user will access it from another computer connected using LAN. I am able to change the connection string to the shared database using Visual Studio 2008/ debugger whenever the server changes but how am I supposed to do that when it’s software?
-
There will by many clients. Am I supposed to give the same software to every one, so they all can connect to the database? How will the integrity and correctness of the database be maintained? I mean the db.mdf file will be in a folder which will be shared with read and write access. So it’s not necessary that only one user will write at a time. So is there any coding for this or?
1) One option is to package and deploy your application with Installshield.
2) Have your application pull the connection string from an app config. I’ve seen (and done) this by having an XML file with general configuration settings (like database connection strings), that sits on the file system and is in the same directory as your executable, and is read as your executable is started.
3) Generally, SQL Server will handle most of the concurrent data reads/writes and keep the integrity of the data in-tact (as long as you’ve structured your tables decently).
Since you’re going to deploy this app to multiple machines, it sounds like you could just install your application client on X machines, and they’ll access the SQL Server database on the database machine. If you do this approach, you won’t need to share the db.mdf file as it will only need to be accessible by the SQL Server, which the application will access.
I hope that helps.