controlling search relevance in MySQL -


What are the possible ways to control search engine optimization in MySQL? Let us suppose that we are building a search engine for a small web store where buyers can add goods to sell there. The table is: Make the table 'Product' (`id` INT not the pure octangrement primary key, 'title' VARCHAR (100) No, zero,` date` not date, 'buyer_level' INT (2) No, complete, full mark (`title`)) engine = MYISAM;

I want to give a weight for the following factors:

  • Title: Match input keyword with title, weight = 10 do .
  • Buyer_Level: Higher is better level 10 for gold buyer, bad buyer 1. weight = 5
  • Date: new is better weight = 5

The question is, How do we create the result of MySQL output based on the value of the weight?
Example:
If we have the following lines in the table:
1, iPhone, 22-5-2010 9
2, iPhone, 22- 5-2010,1
If the user searches about Iphone, the first line should come first and the second line should be finalized because the first one is more than the other.

can not actually put weight on the date unless you are more closely defined 'new' do.

  command (IF (title '+ explorer _ level + IF (5 - DATEDIFF (now (, date) & lt; 0,0,5 - DATEDIFF (date, now ()) )) DESC,  

Comments