fulltext question

2013-11-26 Thread Jim Sheffer
Hello all-

I have a question on searching via fulltext.

I have the following SQL statement:

var('SQLResultsID') = 'select *, MATCH 
(product_id,product_name,product_desc) AGAINST(' + $sqlKeywordSearch + ') AS 
SCORE from products WHERE MATCH (product_id,product_name,product_desc) 
AGAINST(' + $sqlKeywordSearchB + ' IN BOOLEAN MODE) AND active NOT LIKE 
%no% ORDER BY score DESC

First off, the variable $sqlKeywordSearch contains the search keywords 
separated by spaces.  The second variable, $sqlKeywordSearchB, has keywords 
separated by spaces but also adds a “+ sign to the beginning of each keyword 
to do the Boolean search and match all the keywords in the search.

question #1 - Is this the best way to do a boolean search but also return a 
usable “score”?  The search is doing what I expect it to do so no problem there.

Here’s my main question: I want to be able to “boost the rankings(score) of 
the results based on the fields.  Anything that matches on the product_id field 
I would like to get a higher ranking, then the product_name field next, then 
the product_desc last (obviously, if something matches in the product_id field 
it is of greater importance than if it matches in the product_description 
field).  I know I can boost, or adjust, the score to the keywords if I want 
but is there a way to add to the search score rankings based on the field 
searched?

as always, Thank everyone for any help!


James

James Sheffer  j...@higherpowered.com
Lasso Developerhttp://www.higherpowered.com
phone:  469-256-0268




--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



restore question

2013-07-05 Thread Jim Sheffer
Hi everyone-

This is probably a no brainer (I'm new to Navicat) but I have a backup of a 
database from Navicat.

I want to be able to see if a certain field has changed since this morning in 
the backup (We are having problems with an order that somehow duplicated the 
items.  I need to see if there was only 1 of each item or two removed from 
inventory).  I don't need to do a restore into the database, just have a look 
at the backup.

Is this possible without going through the hoops of creating a copy of the 
database and restoring to the copy (I assume this is possible) - I DO NOT want 
to restore into the currently running database :-)

Any suggestions would b greatly appreciated!


James Sheffer,

The HigherPowered Team!

supp...@higherpowered.com  sa...@higherpowered.com
Web Design  Development http://www.higherpowered.com
phone:  469-256-0268   
 We help businesses succeed on the web!
 ---


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql