Start a new topic
Answered

Sorting inside KinveyRef dictionary

How can I sort objects by date inside kinveyRef dictionary ?

Thank You 


Best Answer
Hi, searching or sorting on data inside an object referenced by a KinveyRef is not currently supported. You could either sort on the client side after receiving the response, or write a Business Logic post-fetch hook to do the same.

 


H Wood,

Let me know if this works.

 let dataSort = KCSQuerySortModifier(field: "_kmd.lmt", inDirection: KCSSortDirection.Descending)
 query.addSortModifier(dataSort)
        
 store.queryWithQuery(
            query,…


Thanks,
Pranav
Kinvey Support

 

Thank you Pranav, but your solution didn't help me. 

Thank you Pranav, but your solution didn't help me. 

Answer
Hi, searching or sorting on data inside an object referenced by a KinveyRef is not currently supported. You could either sort on the client side after receiving the response, or write a Business Logic post-fetch hook to do the same.

 

Login or Signup to post a comment