Hi,
I have already made a fulltextindex and it works pretty well with score and distance (calculating distance from the user and the record). However I would further like to improve this search by giving first the records with phone numbers and the ones that are "reserved".
I tried adding more columns to the order by, this does not seem to work as I had hoped it would.
(No difference in the first records).
I think there are two ways (probobly many more) to solve this:
1. Use some kind of case() to check the column reserved and order by this ( I doubt this will work better than order by the column reserved and phone )
2. Make some if/else code and making a variable that I set to 0.5 if reserved, 0.4 if has no phone no, 1 if has phone no and is reserved. Then adding the value of this variable to the score (score on the match()).
Hope this makes any sense
Olav Alexander Mjelde
I have already made a fulltextindex and it works pretty well with score and distance (calculating distance from the user and the record). However I would further like to improve this search by giving first the records with phone numbers and the ones that are "reserved".
I tried adding more columns to the order by, this does not seem to work as I had hoped it would.
(No difference in the first records).
I think there are two ways (probobly many more) to solve this:
1. Use some kind of case() to check the column reserved and order by this ( I doubt this will work better than order by the column reserved and phone )
2. Make some if/else code and making a variable that I set to 0.5 if reserved, 0.4 if has no phone no, 1 if has phone no and is reserved. Then adding the value of this variable to the score (score on the match()).
Hope this makes any sense
Olav Alexander Mjelde