Sorting Attributes

Hi, I’m having trouble to work with Attributes and I wonder if it’s working or If there is something that I don’t understand.

So I have 2 different ordered attributes : Type and Genres.
When I type “Pop(Genres) Piano Teacher (Type)” every thing seems to work. But when I type Piano Teacher(Type) Pop(Genres), then Algolia seems to provide only the first occurence that’s come and stop sorting things out. Any idea are more than welcome. Hope my explanation are clear enough. Thx in advance.

Update : none of those above work in fact. It just gave me the first occurence. So my question now is : Does Attributes get sorted on array ? and does Attributes tied ?

Are you reffering to the ranking formula and how the results are sorted? Maybe this guide could help you: https://www.algolia.com/doc/guides/relevance/ranking/#guides

Hi Bobylito, Yes I’m referring to that and already read the guide a couple of times but can’t find if the Ordered Searchable Attributes are also pass thru the Tie-Breaking Algorithm. To summarise, if the first attribute is tied then, does it get sorted with the second attribute and then the third and so on ?

Yes the searchable attributes answers to the same tie breaking logic: https://www.algolia.com/doc/faq/index-configuration/what-should-i-put-in-searchable-attributes/#faq-section

Thanks Bobylito, but from your FAQ, it’s not saying that when there is a tied for the first attribute it will sort them with the second attribute. But if you say so, I’m trusting you but that’s leads me to the question why it’s not working for me ? and do you think it can from the fact that we are using an array ?

Ok, I just tried without an array and it seems to not working either. So I’m gonna try to explain to you what I’m looking for and you will be able to help me from there hopefully… So, when I type Piano Teacher Pop, the engine should go to the first attribute to look for a Piano teacher and then jump on the second attribute which is Genres to find Pop.

From there, everything works fine, algolia is finding those words on each attributes. But considering that genres are ordered, if the same genres appear on 2 different records, algolia should show me the one with the first matching word first ? but it doesn’t. For exemple if I got Piano teacher : Pop / Rock and an other Piano teacher : Rock / Pop if I search for piano teacher Pop it should show me the first example but instead is showing me the second. Hope is getting clear…

Does anyone have any clue ? How can I reach Algolia support ?