I'm using a NSFetchRequest for searching for users. In addition to sorting the results by name alphabetically on first name or last name partial matches (which I am already doing), I would like to bring exact matches to the beginning of the list.
For example, search string = "Abra Kadabra" currently shows
- "Abra Abra"
- "Abra Blab"
- "Abra Kadabra"
- "Blob Kadabra"
- "Cookie Kadabra"
But I would instead like it to show
- "Abra Kadabra"
- "Abra Abra"
- "Abra Blab"
- "Blob Kadabra"
- "Cookie Kadabra"
I already tried using a block sort descriptor, but because I am using Sqlite for Core Data, that is not possible.