Re: concurrency for asp.net

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: i9arcanes (i9arcanes_at_discussions.microsoft.com)
Date: 02/03/05


Date: Thu, 3 Feb 2005 15:03:03 -0800

One would not prefere to get locked until others decision.. It will be very
irritating for other customer if he has to wait for someone else to make
decision. and even someone can block the reservation for a long time...
   What i would suggest is, to check the available flag each time you update
the record and you can through message if meanwhile someone has already
booked that seat.

"Kevin Spencer" wrote:

> I think you'll have to keep track of any customer considering a booking, and
> disallow any other customer from trying to check the same booking until the
> first has made a decision one way or the other. You could do this with
> Application-level variables.
>
> --
> HTH,
>
> Kevin Spencer
> Microsoft MVP
> ..Net Developer
> Neither a follower nor a lender be.
>
> "angus" <angus@angus.com> wrote in message
> news:OZxouOhCFHA.3592@TK2MSFTNGP09.phx.gbl...
> > Hi all,
> >
> > I would like to seek help on the topic about concurrency in asp.net web
> > application
> > for instance, my application is going to implement a online restaurant
> > table booking system
> >
> > i have a db table to store all tables in the restaurant, lets call it
> > res_table
> >
> > in res_table, there is a table_id field, as well as a flag called
> > is_available, if the table has been booked, is_available=0, otherwise,
> > is_available=1.
> >
> > normally, when a customer is going to book a table, i have to validate if
> > the table is_available=1. right?
> >
> > now, there are two customers are going to book the same table almost the
> > same time,
> >
> > the timeline would be as follow:
> >
> > customer a -> check if < res_table xxx > is_available=1
> > customer b -> check if < res_table xxx > is_available=1
> > customer a -> book table xxx
> > customer b -> book table xxx
> >
> > so, the data is wrong.
> >
> > how to solve the problem? any good article is talking about that issue?
> >
> > Thank you.
> >
> > Regards,
> > Angus
> >
>
>
>



Relevant Pages

  • Re: agile/xp question (formal analysis)
    ... >booking system that you can sell to their competitors, ... The reason being that big teams produce more in a shorter time ... >in a shorter time frame (and more money will be lost if something goes ... Customer for a large project in many cases can often be a country (or ...
    (comp.object)
  • customise primary Key
    ... creating booking system for repair. ... for both tables i need to create a customize key for customer ... year and finally a unique intger for example ...
    (comp.databases.ms-sqlserver)
  • Re: Joke for Anne re: phone service
    ... Maybe I wouldn't have gotten so irritated if I had some testicles to play ... A real-life customer complaint letter sent to NTL (to their ... be transferred to someone and then been redirected to the irritating ...
    (alt.support.stop-smoking)
  • Re: Joke for Anne re: phone service
    ... Maybe I wouldn't have gotten so irritated if I had some testicles to play with while I waited on hold... ... A real-life customer complaint letter sent to NTL (to their ... be transferred to someone and then been redirected to the irritating ...
    (alt.support.stop-smoking)
  • concurrency for asp.net
    ... I would like to seek help on the topic about concurrency in asp.net web ... my application is going to implement a online restaurant table ... the timeline would be as follow: ... customer a -> book table xxx ...
    (microsoft.public.dotnet.framework.aspnet)