Jump to content

Recommended Posts

I believe the search facility on these forums utilises Sphinx. I've used it on a couple of projects, depending on your data set and what you want to do with it, it can be extremely fast compared to something like MySQL. I had queries that took ~20 seconds on MySQL compared to less than a second on Sphinx.

Link to comment
https://forums.phpfreaks.com/topic/213716-sphinx/#findComment-1112409
Share on other sites

  • 3 weeks later...

 

I believe the search facility on these forums utilises Sphinx.

 

 

Indeed.

 

 

Considering the speed you get from sphinx, do you think this query matches the performance:

 

 

$string = "foreach loops";foreach(str_word_count($string,1) as $word)$search_sql .= "+{$word} ";$res = mysql_query("SELECT * FROM `freaks` WHERE MATCH `topic` AGAINST('{$search_sql}' IN BOOLEAN MODE) ");

 

 

I have  40 Million + rows with 10 GB data and get queries < 0.5 secs

Link to comment
https://forums.phpfreaks.com/topic/213716-sphinx/#findComment-1119704
Share on other sites

Considering the speed you get from sphinx, do you think this query matches the performance:

 

$string = "foreach loops";
foreach(str_word_count($string,1) as $word)
$search_sql .= "+{$word} ";

$res = mysql_query("SELECT * FROM `freaks` WHERE MATCH `topic` AGAINST('{$search_sql}' IN BOOLEAN MODE) ");

 

I have  40 Million + rows with 10 GB data and get queries < 0.5 secs

 

Yeah, I'd imagine that'd be cut down to at least 0.2sec, if not less.

Link to comment
https://forums.phpfreaks.com/topic/213716-sphinx/#findComment-1119791
Share on other sites

i finally got sphinx up and running on my site, but i'm using it for testing purposes right now, though.

 

Well i managed to get my mysql queries down to < 0.3 secs (front end) by delaying key write, setting default order and using fulltext - let me know what you get.

 

Im working on a mod to get asynchronous results from mysql and instantly display them when a user clicks "submit", its more of a trick though

 

 

Link to comment
https://forums.phpfreaks.com/topic/213716-sphinx/#findComment-1120728
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.