Database application across more than one site

I have a very simple WinForms application written in VB.Net and using MSDE; the application keeps track of vehicle bookings.  This works great on a standalone machine, but if the business owner wishes to open up another branch several miles away, I need to know the best way of altering the application to allow both sites to share the same database - rather than each branch manager making 200 telephone calls a day trying to see if the other branch has a certain vehicle available.  So...

What do I do...?

So as not to appear lazy, I'll make some suggestions:

1.  Get the business owner to invest in a Wide Area Network connection.
Presumably this would enable me to install the application on two (or more) PCs and simply tell both applications where the database is located???  Is this a realistic appraisal of what is required to operate over a WAN, or am I in for a rude awakening?!!   :D

2.  Modify the application to allow it to "tell" the other machine that a booking of "vehicle number 25" has been requested -- eg by sending/receiving e-mails to and from whichever machine is running it.  I guess the logic to this might be difficult to perfect, and might create problems (eg. double-bookings etc) if there is any delay in the e-mail being sent or received. Also, I have never attempted e-mail communications within the guts of an application, so I find this idea unattractive to say the least!   :D

3.  Learn ASP.Net.  I know little or nothing about this topic.  Presumbaly, it would allow me to have the database hosted on a remote server (or website??) somewhere and have each application access and update the database as necessary?  Would the business owner need to buy a website?

Please give me a some feedback on each of the above suggestions.  Or if there is another way then please let me know.  I'm meeting with the business owner tomorrow so swift responses would be swell!!  And I know that answering this question properly will cost you the best part of an entire lunchbreak, so the full 500 big ones are up for grabs.

Thanks in advance.
Who is Participating?

You should be able to use MSDE with multiple user if you use it normally.

But I was asking myself: (Sigh_Man...)  why not use MySQL?? You have no user/workload-limitations or whatsoever.

Read this article (with a very bright example):

( If you have .Net Framework v1.1 installed, you don't need to install any drivers to be able to access any mySQL database (MyODBC driver is defined in the System.Data assembly!). Else, if you have v1.0, you can download the driver from here:

I use it myself.. its free and works great!!

Try it and maybe you like it!

I would personally go for the web approach (
You wouldn't have to invest in a webserver, RDBMS etc.., most providers will have an option to provide and host it for you (in exchange for some monthly fee:-)).
I think most of your VB code will still be usuable (except for the userinterface part). You will ofcourse have to learn but that seems to me like a big plus.
And I would invest some resources in security.

Option 1. Is a possibility but that would not work with the MSDE you would need to invest in the full SQL server. I don't know how it is over where you are but that WAN connection is pretty expensive over here, and if more branches are planned for the future.

Option 2. That option doesn't appear to  be a save way to go at all. There are to many weak spots in that approach.
Sigh_ManAuthor Commented:
Thanks for that.

I agree that Suggestion number 2 would be heading for disaster!

Just a few questions:

1.  Do you recommend any particular books on ASP.Net?  (I've generally found the Wrox books pretty OK)

2.  There's some stuff in my current texts on "Web Forms" and "Web Services" -- does ASP.Net encompass both topics or are these totally separate?  Or should I just forget them?!

3.  Do I need to buy SQL Server before I can start learning ASP.Net?  Or is there a mock-webserver built into Visual Studio?  Or is there something similar to MSDE that I could use??

4.  (Back to the original question on the hire business...)  Is it possible to build a WebService that my existing WinForms application(s) can use to share data?  Or does building a Web Service require additional H/W and S/W that I can ill-afford???  (Or should I stop being scared of the unknown and start learning ASP.Net?!!!   :D  )

5.  When learning ASP.Net, is it generally best to make use of some of the 10Mb webspace that comes with my ISP account - to practise accessing/updating stuff - or is it easy to learn it all whilst disconnected and then simply migrate the webserver parts to a 'real' web server prior to deployment of the finished application?

6.  When you say "invest some resources in security", is security just another part of ASP.Net or are you talking about security in terms of Firewalls on the business's PCs etc?

I'm determined to get up to speed with ASP.Net so I will probably treat myself to a new book at the weekend!!  I want to ensure that I am in a position to deliver multi-site database solutions in the future.

Thanks again.
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Sigh_ManAuthor Commented:
I won't ask any more after this, by the way!!    :D
1. I personally found these very good

but stay away from this one it's rubbish

2. ASP.Net and encompass both topics
3. No you don't, you can still use your MSDE or Access for that mather (but MSDE is single user)
4. I think there is (Cassini), otherwise
5. You can do both, I build and test locally and from time to time I upload to the our webserver to test if it work there aswell.
6. No, your ISP will have handled that (I hope ;-)) but look at the book I recommended about building secure ASP applications

I you have further question, just ask.
Sorry, regarding point 5. Your ISP will have to support the .net framework if he doesn't it won't work
Sorry again I forgot to answer point 4. I never had to acquire extra hard- or software to begin using
Just do, and when problems do occur just ask the experts here at EE. That always solved my problems

answser to question 1: the book of WROX on ASP.Net is a M.U.S.T. !!

answser to question 2: You can use them, since you are able to program "" webservices. So the difference is mostly you program the same language for webpages with some differences but most of the code on the serverside looks very very familiar if your're used to VB.Net.

answser to question 3:  you can download a free version of MSDE:

answser to question 4: Your webform application should be able to contact your webservice. Look at this example:

answser to question 5: The Asp.Net code won't run on your ISPaccount. They need to have support for ASP.NET!! Ask them... But don't worry, if you are using windows XP (pro?) ,.. you can run your webpages/services using the build in Internet Information Services (ISS). If not installed, check configuration manager>software>windows components

answser to question 6: ... I did not wrote the last post ;-)


What you also could do is this:

Make sure all computer are hooked up to the internet (online). Put your database online and configure your application to open the SQL database via internet.... If you use a cheap MySQL database (most ISPs/hosting comp. use them) then you might need to alter some of your work.

The big PRO on this is that you wont need to learn and rewrite the app in I don't know how big it is,.. but all the userinterface needs to be reconsidered

The bit Pro of using asp.Net is the users need only a PC that online and a username/password to gain access...

For everything is something to say.

About security: my idea is more secure since 'a bad' person can get more easily track of your database and try to hack it (for what reason) in ASP.NET enviroment than an application that they don't have...
Sigh_ManAuthor Commented:

  >>>3. No you don't, you can still use your MSDE or Access for that mather (but MSDE is single user)

I read on the internet that MSDE can support up to 25 users on a website.  Other than web applications, is it right that MSDE is single user only?  I thought it could support multi-user, as long as each instance of the application 'knows' the location of the database - even if it was across a network...???

Sorry to re-hash the same question, but this is a bit of an upset for me if I cannot program multi-user applications without upgrading to SQL Server.

Thanks again...
Sigh_ManAuthor Commented:
Sorry - that last point of mine was in relation to WinForms applications in VB.Net by the way.

The SQL server is free to serve up to 25 ppl. ("...Basic websites that serve up to 25 concurrent users....")
If you go beyond that number you've to pay. (Maybe the single-user is amount of installs you can do with the same installation... but thats def. NOT)

so you're still in!

Sigh_ManAuthor Commented:
I know that is true for websites, but I wanted to know if there is any way I can use MSDE across LANs or WANs.

I read on the MS website that MSDE must be installed with the application that is going to use it.

So, for example, if I had a client who has a LAN in his office with say 5 PCs -- can I install my WinForms database application onto ALL 5 PCs but have each of the 5 applications accessing just ONE SQL database contained on MSDE?
- Can this be done?  Or does it require full blown version of SQL Server instead of MSDE?

You can do exactly as you descibed!

That the whole idea of a database... but you cannot let more than 25 ppl use the database in on time... then the get the connection refused!

Hope thats convincing you...

It indeed not very clear but read this

("... MSDE 2000 is a local data engine that can be shared ...")

And this security note on the MSDE 2000 version

Read this:  (".... However, MSDE 2000 can handle most mid-range client/server projects and moderate-load Web applications with aplomb...."

So as I posted earlier: you can better stick with your Windows Application (rather than programming it again in ASP.NET) and use this SQL solution!

Good luck,... Daniël
Sorry I didn't know about the possibilty that MSDE could have more than one concurrent user, I've tried that a million times and never been able to get it to work. I can access over the LAN but never with more than one user at a time.
Is there a setting in there daniellus83, during install or something because when I try it the second users connection is always refused.
Found this in the Microsoft SQL Community:

> I thought that MSDE had a limit of 10 concurrent users?  Is it 25?

No, it is neither.  As I tried to explain, MSDE doesn't have a limit on
concurrent users at all (not 5, not 8, not 10, not 25, not 5000).  There is
a governor that throttles performance at or around 5 simultaneous workloads,
which is *NOT* the same as a connection.

The 25 was a *suggestion* on one of the product pages, for how many
concurrent users a typical system running MSDE could support.  This could be
completely different from project to project, as hardware, application code,
usage, bandwidth, database design etc. can differ, and all of these things
impact how an application performs.  So you will need to test it out to see
how many simultaneous users and/or workloads your specific scenario can

To provide an analogy for the difference between a concurrent user and a
concurrent workload.  Imagine yourself at the DMV, and there are 40 people
waiting around, not doing much.  Two people are at the registration counter,
and one person is getting her picture taken for a new drivers' license.  The
40 people are "concurrent users" and the other three are "concurrent
workloads" - since they're the only ones actually doing anything productive.

Read also this (about the build in 'Governor'):

Hope it helps.

RonaldBiemans: it might be that the Governor closes down because of the workload... but it sounds of course very strange. I will check my settings... I hope I can help you on this one.
That could be the case, the program I tested it on was quite a behemoth. Thanks
Sigh_ManAuthor Commented:

The responses have been fantastic.  The only difficulty now is allocating the points for the questions when they develop like this...which of carries the risk of tears and upset from the contributors!!  Both responses were tremendously helpful:  I'm going to award the points equally due to the perseverance of both.  I hope that is OK??!!!

Thanks again.  And stick around!!   :D
Haha... I feel the tears already coming... |~.

No way.. I found it amusing... We should do this again!  :-)

I hope Ronald agrees ;-)
Sigh_ManAuthor Commented:
:D   I'm glad to have caused such a fun-packed question!!!

You'll hate me for this, but:  With LANs and WANs, as far as each PC is concerned, is there no difference between accessing data over a LAN or a WAN?  When I am in the office, we use a WAN between our offices - and when I use eg WORD or EXCEL I simply open up a file - whether it is saved on a local drive or whether it is saved in an office 1,000 miles away in our head office.  Is it the same for accessing data in my VB.Net applications?  ie (going back to the Question!) do I simply code the Sql Connection within the application to the location of the database - whether that database is located on a local drive or on a drive on a WAN?

I'm so sorry for asking - feel free to tell me to get lost!!
You've already more than earned the points!!!   :D

no problemo.

It might be confusing.. but a network is a network. You might have Firewalls / routers/ Virtual Private Networks / Combined WANs.. LANS WHATEVER.... :-)...
..but if you are able to connect (with your application) to your own computer (local database) or 1,000 miles away... You just need to fill in the (IP) address of that computer and to connect. So...

If your computer is connected to the internet... and your firewalls and router (?) is configured all right.. AND you are running a local SQL server... then I should be able to connect to your local database (with the correct username password..)

It all about: being connected and having permission (as well as database-access as firewall configurations)

Hope you are now totally cleared up... :_))

Sigh_ManAuthor Commented:

Thanks a lot.   :D
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.