How to use –sortOrder with Json Attribute on LDAP


This topic has 2 replies, 2 voices, and was last updated 6 months, 4 weeks ago by Ludo.

  • Author
  • #28761

    I have a set of Entries in LDAP, each entry has an attribute is Json format as sample bellow:


    My question is how to use ldapsearch with --sortOder to sort with user-custom-atts's attribute?.

    I already try with ldapsearch --baseDn ou=people,ou=sampel01,ou=identities --bindPassword password --sortOrder "user-custom-attrs:caseIgnoreJsonQueryMatch:=/category" --simplePageSize 10 --countEntries "(uid=*leonidas*)" but DS server said that “Unable to process the provided server-side sort request control because it references undefined ordering matching rule caseIgnoreJsonQueryMatch:=/category”


    @ludo hope you can help me, ty sir



    To be able to sort, you need an ordering matching rule. caseIgnoreJsonQueryMatch is a equality rule.

    There is an example of the use of a Json ordering rule in our documentation:

    --sortOrder +jsonToken:extensibleJsonOrderingMatch:true:true:/category is like to achieve what you need.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

©2022 ForgeRock - we provide an identity and access platform to secure every online relationship for the enterprise market, educational sector and even entire countries. Click to view our privacy policy and terms of use.

Log in with your credentials

Forgot your details?