Gossamer Forum
Home : Products : DBMan : Customization :

How to stop keyword search overriding other fields?

Quote Reply
How to stop keyword search overriding other fields?
Hi!

Anyone know how to combine the code for keyword search with that for regular searches?

I notice it's an 'either/or' thing: if you
do a keyword search, it overrides any other (specific) search on a field.

For instance, I have a drop-down box called 'country', which works fine when searched by itself.

But once I enter a keyword as well, the keyword matches against records from ALL countries, even though the user wanted 'Germany', and only German records containing the keyword.

Quote Reply
Re: How to stop keyword search overriding other fields? In reply to
Yep. You are right. It is an either/or thing.

The problem is that the only way the keyword search is to set the "match any" option too. (The script does it automatically.) It would be possible to have the script not override entries in the other search fields, but the result would be the same as it is now.

There's no way that I can think of to have the search require a search term in one field and do a keyword search on the other fields. Possibly I can come up with something later, but right now I wouldn't know where to start.


------------------
JPD





Quote Reply
Re: How to stop keyword search overriding other fields? In reply to
Just a thought -- and I don't know how the inner workings would fall into place -- could you modify the search script to accept values for single or multiple searches? For example, you could send it a (0,0) value which would default to the regular, single search. If you wanted first a search on category #3, then a keyword search, you could pass it (3,*), etc. Somehow you would have to create the search routine so that it knows to hold onto the first search results and then search only that subset when it is called for the second search...

Again, I have no idea if this could work or if it would be easily implemented. Just brainstorming. Smile

Dan
Quote Reply
Re: How to stop keyword search overriding other fields? In reply to
I don't know the inner workings of the search script either. Smile That's just something I haven't dealt with yet.

But I do know that the next version of DBMan will have some other search options.


------------------
JPD