London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!

TypeSearch not able to do conditional sorting

Vote:
 

I am trying to do conditional sorting by pulling the matcing field to search query first and then followed by other sort orders. I tried .OrderBy(x=>x.FieldName==queryParam) and also using .BoostMatching(x=>x.FieldName.AnyWordBeginsWith(queryParam),1) . Any one idea how we can achive this, appreciate any help!

#301187
May 04, 2023 22:03
Vote:
 

I can't really figure your query

For that to work queryParam needs to be the exact same as the FieldName

#301351
May 08, 2023 7:52
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.