Creating Online Forum, Questions...
I was thinking of creating an online forum using Perl. Would it be better to store one text file per thread? I was thinking that any one topic may create a text file that is too large to search quickly. Or would it be better to just use an actuall database to store entries. Any suggestion would be great.
Thanks
G
Mark Hensler posted this at 17:49 — 21st March 2001.
He has: 4,048 posts
Joined: Aug 2000
Perl forums are not all that great. Compair UBB to vBulletin. UBB is written in Perl, and uses a flat file storage system. vBulleting is written in PHP and uses a mySQL storage system. vBulleting is much faster.
Also, if you use on file per whatever, you'll just increase the system load for searches. Because you'll have to open each file, seach it, and close it. Having many files storing your content may increase your spead for viewing threads (if done right).
My recommendation is to use PHP with mySQL (if your server can supports it).
Mark Hensler
If there is no answer on Google, then there is no question.
japhy posted this at 19:18 — 21st March 2001.
They have: 161 posts
Joined: Dec 1999
A bulletin board system is only as good as the database backing it up. Flatfiles are destined for doom. SQL is a far wiser choice, especially for searching.
I strongly recommend using a language that provides a simple interface to an SQL database. Perl, for instance, has the DBI module, which allows you to access practically any kind of SQL (and some non-SQL) databases with the same generic interface.
spragueg posted this at 21:57 — 21st March 2001.
They have: 23 posts
Joined: Jan 2001
Just found out my ISP does not support DBs of any kind. So I think I might try it with 1 flat file per thread and limit searches to single topics. I could also retire treads after 6 months or so. I am doing for fun/learning. Maybe if I get alot of hits I could convert it to use mySQL later and I could pour the flat files into mySQL.
Thanks for the suggestions.
Thanks
G
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.