This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
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.
In a time of drastic change it is the learners who inherit the future. The learned usually find themselves equipped to live in a world that no longer exists.<br />Eric Hoffer
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.
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.