Sublime directory Surf the web anonymous Pagerank Monitor


Whats the best way to do a search?

Mind_nl
Sat 18 February 2006, 09:41 am GMT +0100
I've got a database with a lot of articles and I want to add a search function to the website. What would be the best way to achieve this? The database size is still fairly small but will increase.

Nikolas
Sat 18 February 2006, 11:22 am GMT +0100
Well that depends.

The fastest way for the database, is by having some small VARCHAR fields in your table that indicate keywords.

Those fields should be indexes. But this way will not have the best results.

The best it would be if you would use the article's title or/and text, but this would create a huge overload on the server (that also depends of traffic of course), but you could do this better by creating some kind of cached results for the queries.

Hope my post helps :)

Archive for SMF v1.00 by N.P. Valid XHTML 1.0 Transitional