ElasticGraph Query API: Sorting
Use orderBy:
on a root query field to control how the results are sorted:
query ListArtists {
artists(orderBy: [name_ASC, bio_yearFormed_DESC]) {
nodes {
name
albums {
name
}
}
}
}
This query, for example, would sort by name
(ascending), with bio.yearFormed
(descending) as a tie breaker.