Module: Non-Temporary Search
Posted by Thomas Seifert
All files from this thread
File Name | File Size | Posted by | Date | ||
---|---|---|---|---|---|
non_temp_search.php | 9.1 KB | open | download | Thomas Seifert | 04/01/2008 | Read message |
non_temp_search.php | 9.3 KB | open | download | BillS | 12/11/2011 | Read message |
non_temp_search.php | 9.5 KB | open | download | BillS | 10/20/2014 | Read message |
Module: Non-Temporary Search January 08, 2008 04:59PM |
Admin Registered: 21 years ago Posts: 9,240 |
This module plugs into the search-functionality bypassing the core search implementation
to search without the use of temporary tables (in mysql, won't work with any other layer probably).
Its only purpose is to provide some search functionality for the users which can't get their ISP/host to fix the permissions for allowing temporary tables.
Beware, it might get really slow! Better get your host to fix your mysql-permissions!
For installing and using this module just drop the attached .php file into the mods folder (directly, not into another directory) and enable it through the admin at the modules page.
Thomas Seifert
to search without the use of temporary tables (in mysql, won't work with any other layer probably).
Its only purpose is to provide some search functionality for the users which can't get their ISP/host to fix the permissions for allowing temporary tables.
Beware, it might get really slow! Better get your host to fix your mysql-permissions!
For installing and using this module just drop the attached .php file into the mods folder (directly, not into another directory) and enable it through the admin at the modules page.
Thomas Seifert
Non-Temporary Search hack to fix PHRASE search December 11, 2011 08:19PM |
Registered: 12 years ago Posts: 4 |
Re: Non-Temporary Search hack to fix PHRASE search October 20, 2014 02:45PM |
Registered: 12 years ago Posts: 4 |
The Any Words and All Words searches did not work for me.
I found a bug in the addon where the query built looked like this:
SELECT message FROM table WHERE search_text LIKE ('%term1%' OR '%term2%' OR '%term3%')
but MySQL doesn't like that. Fixed to look like this
SELECT message FROM table WHERE search_text LIKE '%term1%' OR search_text LIKE '%term2%' OR search_text LIKE '%term3%'
and that seems to work! My latest change is prefixed with comment "Bill 101914"
Bill
I found a bug in the addon where the query built looked like this:
SELECT message FROM table WHERE search_text LIKE ('%term1%' OR '%term2%' OR '%term3%')
but MySQL doesn't like that. Fixed to look like this
SELECT message FROM table WHERE search_text LIKE '%term1%' OR search_text LIKE '%term2%' OR search_text LIKE '%term3%'
and that seems to work! My latest change is prefixed with comment "Bill 101914"
Bill
Sorry, only registered users may post in this forum.