When a GraphQL is sent to Stardog, the results are not returned in the same order as they were in the query.
See for example this snippet from the Stardog docs:
Input:
{
Human(id: 1000) {
id
name
homePlanet
}
}
Result
{
"data": {
"name": "Luke Skywalker",
"id": 1000,
"homePlanet": "Tatooine"
}
}
The graphQL spec (http://facebook.github.io/graphql/draft/) suggests:
GraphQL Objects represent a list of named fields, each of which yield a value of a specific type. Object values should be serialized as ordered maps, where the queried field names (or aliases) are the keys and the result of evaluating the field is the value, ordered by the order in which they appear in the query.
I realize that the latest draft says "should" and not "must|shall." However, it would be nice if Stardog would follow this suggestion.