Skip to main content
Quick Summary: Use the orderBy parameter in SkillsDB GraphQL queries to sort results in ascending (ASC) or descending (DESC) order by any supported field.
In most query operations, we provide the ability to sort the result set using the orderBy input parameter. For example:
query getDomains {
  getDomains (input: {
    orderBy: {
      DomainName: ASC
    }
  }) {
    count
    data {
      DomainId
      DomainName
    }
  }
}
In this query, we are asking for the domains but they need to be sorted in ascending order based on the DomainName. The other value allowed is of course DESC:
query getDomains {
  getDomains (input: {
    orderBy: {
      DomainName: DESC
    }
  }) {
    count
    data {
      DomainId
      DomainName
    }
  }
}

Need Help?

If you run into any issues or have questions, reach out to your organization’s SkillsDB administrator or contact SkillsDB Support.