Click here to Skip to main content
15,892,746 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I have written an application in vb.net, based on SSCE. Now I need to shift in SQL Server Express because I need to run the application on Sharing (LAN) and several users need to access the database at the same time.
I am absolutely new to SQL Server. I need to know the following:

1) Do I create SQL Server DB by Adding New Item in my VS 2008? or they need to be created in SQL Server mgmt Express ONLY?

2) How do I distribute these database, same way like SSCE databses?

3) Can these databases be used like we use Access DBs in sharing (just put in the shared folder)?

4) If no to Question 3, how to set the connection string as I donot know the name of computer of the user who will install my application.

Thanks
Posted

1) Find a central computer/server which will act as a base for the database.
2) Install a SQL Server instance onto the server identified in step 1.
3) Install the database you wish to share among the applications into the DB instance created in step 2.
4) Make sure your connection strings are correctly configured in your appliation.
5) Go ahead and distribute your application. If the clients have access to the server then you should be ok.

The moment you go ahead and share a database between multiple users, I would suggest using a database instance and not a shared file (Access-like).
 
Share this answer
 
Comments
thatraja 10-Jan-12 14:33pm    
Perfect, 5!
Wendelius 10-Jan-12 15:07pm    
Exactly, +5
Furqan Sehgal 11-Jan-12 4:41am    
So the setup will take my databases jut from the instance of SQL server or I need to include these databases in setup?
fjdiewornncalwe 11-Jan-12 11:05am    
Your setup will not need to interact in any way with the SQL Server. The sql server instance will be a one-time installation that all the separate applications then simply read from to get their data.
Exactly as Marcus pointed out.

To emphasis the security concerns, no user has to know where the database file reside, just to be able to connect to the SQL Server service.

Also few links you may find useful:
- Installing SQL Server 2008[^]
- How to: Install SQL Server 2008 R2 (Setup)[^]
- Configuring SQL Server 2008 R2[^]

And as you now have (almost) the full capabilities of the SQL Server in your hand, also have a look at these:
- Securing SQL Server[^]
- Backup Overview[^]
 
Share this answer
 
Comments
Furqan Sehgal 11-Jan-12 5:41am    
Thanks !

I made an instance of SQL Server Express and connect it with a basic report. On the development server, it works ok.

Then I shared the folder and then ran the application from some other network computer (LAN)

It gave error that it could not find the server. Could you advise what could be the problem.



Thanks
Wendelius 11-Jan-12 11:26am    
Sounds like you're not actually connecting to an existing database in an existing instance but instead attaching the database to an instance perhaps by the connection string. If this is true, connect the instance instead of attaching the database and just make sure that the database is permanently attached to the instance.
Furqan Sehgal 11-Jan-12 11:58am    
Thanks for the response. What I am doing is creating the database within instance using SQL management studio. Is it right way?
Secondly I am using this in my typed database, where I select server instance first and then choose database below.

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