neo4j-graphql-java
neo4j-graphql-java copied to clipboard
Add support for aggregation queries
Augment schema with fields for aggregation queries.
Given schema
type Movie {
id: ID
actorCount: Int
averageRating: Float
isActive: Boolean
}
Should generate the following augmented schema (partial example with only relevant fields and types below):
type Query {
moviesAggregate(where: MovieWhere): MovieAggregateSelection!
moviesCount(where: MovieWhere): Int!
}
type MovieAggregateSelection {
actorCount: IntAggregateSelection!
averageRating: FloatAggregateSelection!
count: Int!
id: IDAggregateSelection!
}
type FloatAggregateSelection {
average: Float!
max: Float!
min: Float!
}
type IDAggregateSelection {
longest: ID!
shortest: ID!
}
type IntAggregateSelection {
average: Float!
max: Int!
min: Int!
}