3

We have a website written in Codeigniter framework. Now we want to have a nice and fast soundex based search function to the site. It's just a micro blog so we would only search in the titles of the posts.

So what would be the best for us?

I have two ideas:

  1. Create another column in the post table with the soundex copy of the title and simply have FULL-TEXT index on it.

  2. Explode the words from the titles and save the soundex equivalent of the words in a new table with the id of the post. Just like an automatic tag system.

Which method is the better and why? Can you suggest a better way?

Thanks for all the answers!

2 Answers 2

1

Soundex is great - but it usually doesn't meet user expectations for search (established by Google etc.).

The common solution to text searching, including fuzzy searches and stemming, is to use something like SOLR; it's relatively easy to integrate with PHP using web service calls.

The Zend framework has Lucene integration (never used it, but it might save you some time) - Lucene is an open source free text search platform .

1
  • Thanks for your answer Neville, I'm just trying SOLR. I installed and started successfully (ubuntu 11.10), however I can't reach it through ipaddress:8983. I checked "netstat -l" and port 8983 is listening when SOLR is running. Don't you know what can be the problem? By the way how SOLR affects performance? Do you have any experience? My server has 1128MB memory with 2.1GHZ cpu. Aug 8, 2013 at 15:02
0

May use Double Metaphone algorithm

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.