• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Q on Concurrent Accessing

 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

Can I assume that only one program can access the database file at a time. In that case, we only need to handle the concurrent accessing on server side but not database file, which is much easier. But I dont really like this way to program, 'cause it is way less efficient than the way to asscess database file by mutilple threads (clients). What do you think?
[ August 27, 2004: Message edited by: Walter Tang ]
 
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You should read your requirements carefully. I did the URLyBird project a very long time ago and it specifically said that we could assume only one program was accessing the database file at a time.
 
Walter Tang
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Nathaniel Stoddard:
You should read your requirements carefully. I did the URLyBird project a very long time ago and it specifically said that we could assume only one program was accessing the database file at a time.



Hi Nathaniel, Thanks for your reply.

Yeah I read that too. But I am just alittle confused. In the database interface, it asked me to implement the lock and unlock record. I am just wondering if we handle the concurrent accessing of multiple clients at server level, why should we implement the lock and unlock on database record since only one client program will acess the file.
 
Walter Tang
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Nathaniel Stoddard:
You should read your requirements carefully. I did the URLyBird project a very long time ago and it specifically said that we could assume only one program was accessing the database file at a time.



Hello again,

I just solved my question by searching an old postpost
 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Walter,

They said you can assume one program can access the database, and that dose not mean one thread only can access the database, those tow things are completely different.

When they say one program can access the data file that mean there is only one server accessing the database, and there is no other program accessing that data file in the same time, for example you can assume there is no editor program accessing that file or there is no other server accessing that file.

But still in your server program it will handle concurrent client�s (multi threads).
 
Walter Tang
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Omar Kalaldeh:
Hi Walter,

They said you can assume one program can access the database, and that dose not mean one thread only can access the database, those tow things are completely different.

When they say one program can access the data file that mean there is only one server accessing the database, and there is no other program accessing that data file in the same time, for example you can assume there is no editor program accessing that file or there is no other server accessing that file.

But still in your server program it will handle concurrent client�s (multi threads).



Hi Omar, I see the difference. Thank you very much for your help
 
PI day is 3.14 (march 14th) and is also einstein's birthday. And this is merely a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic