Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Re: How do i alter the sql search

Quote Reply
Re: How do i alter the sql search In reply to
Hi,

You could do that... if you gave the location field a weight of, say 100, then it would eclipse anything else, and your sorts would essentially be by location and within that by other points.

The code I gave before didn't work? By adding the location field into the query string, and forcing an "and" it should have worked, albeit a bit restrictive on the searches.

Something changed in the search routines in the last release, and I think it's being worked on, since a lot of people (me included) wanted to be able to return the searches based on something other than "score" order.

I _know_ there is a way to pass extra information to the search routines. Did you check the FAQ for "search" ?? That's probably about where I left off, (and I need to catch up!!)

What didn't work in the code above?

On your form, get rid of the 'or' and 'and' options, and make the field a "hidden" field and have the value set to "and". That will force the two fields to be joined with "and" but it will also mean you can't do searches like "rain or snow" ...

It _should_ work, and is at least a temporary solution.

You should only get records that have that as a match.

Let me know what is happening, and maybe I can fix the code I gave to work right. Check the logic I gave above... and make sure your location drop down box is called query2!






------------------
POSTCARDS.COM -- Everything Postcards on the Internet www.postcards.com
LinkSQL FAQ: www.postcards.com/FAQ/LinkSQL/








Subject Author Views Date
Thread How do i alter the sql search jasonx 4431 Feb 25, 2000, 3:42 PM
Post Re: How do i alter the sql search
pugdog 4328 Feb 25, 2000, 5:07 PM
Post Re: How do i alter the sql search
jasonx 4317 Feb 25, 2000, 6:16 PM
Post Re: How do i alter the sql search
Bmxer 4322 Feb 26, 2000, 11:41 AM
Post Re: How do i alter the sql search
jasonx 4342 Feb 27, 2000, 7:22 PM
Post Re: How do i alter the sql search
jasonx 4320 Feb 28, 2000, 12:36 AM
Post Re: How do i alter the sql search
Karen 4332 Feb 28, 2000, 5:29 AM
Post Re: How do i alter the sql search
pugdog 4332 Feb 28, 2000, 9:36 AM
Post Re: How do i alter the sql search
pugdog 4318 Feb 28, 2000, 6:18 PM
Post Re: How do i alter the sql search
jasonx 4325 Feb 28, 2000, 8:14 PM
Post Re: How do i alter the sql search
pugdog 4326 Feb 29, 2000, 7:27 AM
Post Re: How do i alter the sql search
Alex 4330 Feb 29, 2000, 7:34 PM
Post Re: How do i alter the sql search
jasonx 4331 Mar 1, 2000, 10:29 AM
Post Re: How do i alter the sql search
pugdog 4334 Mar 1, 2000, 5:11 PM
Post Re: How do i alter the sql search
klangan 4320 Mar 1, 2000, 7:49 PM