I have a search setup on an intranet site for my company that works pretty good. I do wish it would work a little better, but I'll have to settle for what I have. Let me explain what I'm doing. When a search is made, I run the word through several tables in my database and use FULL TEXT matching on certain fields in those tables to produce results. I have it set to BOOLEAN MODE so "prod" returns results with "product". As I search through each table, I insert each result into a table I create based on a user's session id. Once I check all tables, I then then run one last query to display the results. Then I drop the table created at the beginning of this process.
The problem is, sometimes the table doesn't get dropped. I don't know why or how, but I end up with a few empty tables in my database at the end of the month. Any ideas as to what could be causing this?
Also, my other issue with this process is I'm using a 'relevance' field to get a "score" of each result, however it seems with BOOLEAN, they all return with a score of "2" or "1", which results in an irrelevant sort order. When I was using standard FULL TEXT search without BOOLEAN, it would return some percentage (like .22340580212). Problem with that method though was it wouldn't return "product" when searched for "prod". So my questions are, i guess:
1. Is there a better way to do this?
2. Is it possible to have the best of both worlds with BOOLEAN and standard FULL TEXT searches?
And the reason i'm not using "LIKE" anymore was 1. I hear this way is much more efficient and 2. there isn't the relevance (or score) feature with LIKE.
The problem is, sometimes the table doesn't get dropped. I don't know why or how, but I end up with a few empty tables in my database at the end of the month. Any ideas as to what could be causing this?
Also, my other issue with this process is I'm using a 'relevance' field to get a "score" of each result, however it seems with BOOLEAN, they all return with a score of "2" or "1", which results in an irrelevant sort order. When I was using standard FULL TEXT search without BOOLEAN, it would return some percentage (like .22340580212). Problem with that method though was it wouldn't return "product" when searched for "prod". So my questions are, i guess:
1. Is there a better way to do this?
2. Is it possible to have the best of both worlds with BOOLEAN and standard FULL TEXT searches?
And the reason i'm not using "LIKE" anymore was 1. I hear this way is much more efficient and 2. there isn't the relevance (or score) feature with LIKE.