• 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

GuestBook Servlet

 
Ranch Hand
Posts: 216
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi to all!
Which is better for implementing a guestbook?: a database storage approach or a flat-file system approach? I am aware that a db allows better searching and data view. However, I am not sure as to how much data a db can hold. Which one can hold more?: a txt file or a db?
Where can I find information about the amount of data that different dbs can hold. I am interested in MySQl and MS Access.
Looking foward to your help.
Thanks.
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, let's see. A text file would be theoretically limited to the size of your hard drive. Databases often include low-level technology to cross multiple hard drives with RAID. I've seen databases in the hundreds of Terabytes (1 Terabyte = 1000 Gigabytes)...
More practically, a search through a text file would be linear. Searches through databases are optimized with indices to be logarithmic or better...
Also, a database can be run on a different machine from your servlet. This allows you to take advantage of the processing power of two machines. With a text file, well, your're kind of stuck there...
Kyle
------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
See my homepage at http://members.aol.com/kgb1001001 for other WebSphere information.
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First thing, think about what you hope to achieve. If you want a guestbook with 2-3 fields, then this would be fine for a text file. If there's going to be more info fields or loads of information (a forum like this) then a database might be a better option. Though I believe this forum is on a flat-file not a database.
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Rob J Ford:
Though I believe this forum is on a flat-file not a database.


I am surprised by this. I'ed be really interested to find out why this storage option was selected as there's a lot of info in this forum. Anyone got any inside info ?
 
ernest fakudze
Ranch Hand
Posts: 216
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot everybody for your insights. I will convert from flat file to database. It seems like a good idea.
Thank you very very much!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic