PDA

View Full Version : Database search which ranks results


nibo
04-01-2009, 10:46 AM
Currently using DataAssist 1, although thinking about upgrading to 2. ASP and Access DB.

As part of a shop I'm building I would like to include a simple keyword search box which looks for matches across 2-3 fields. I would like the results to be listed in order of relevance. Is this possible?

i.e. search page results are filtered on three fields - manufacturer, model and description. If the user enters "remo pinstripe", how can I make sure that the resulting recordset lists the most relevant records first?

Is it possible to weight the results toward a particular field, for example, the manufacturer?

I'm not quite sure how best to set-up the search in DataAssist. Should I just add one item which is set to compare with all of the columns I want to search or should I add a separate line for each of the columns I want to search and use the AND and OR separator?

I'm also not clear on the difference between a "value" and a "keyword".

Sorry, lots of questions. I hope someone can help. Thanks.

Ray Borduin
04-01-2009, 01:57 PM
DataAssist won't help you order by relevance.

Keyword allows you to search across multiple columns. You should probably just use that. Then you would have to find a way to calculate the relevence and order it accordingly since DataAssist does not include that feature.