GraphQL aggregation - issue with filter & limitations for sum


I have enabled aggregate permissions for the data source that i want to get a summary for, and the query was generated correctly.
However, there are 2 issues with it:

  1. My data source is called Lanesoknad, and it has property lanebelop (integer). I want to use aggregation to get a sum of lanebelop of all Lanesoknad. Lanesoknad is a large data source (>20000 entries) and lanebelop in average is >1.000.000. Since the generated for lanebelop_sum field is of type int, i’m getting error message": “Int cannot represent non 32-bit signed integer value: 5867138350”, (and that is even on dev environment, with much less data). There is a ‘caseAgent’ property or ‘status’ that i can try to group results by, but it won’t work on production, because in many of that group elements, the aggregated sum will still be larger than int.
    So the question - do you plan a feature where the aggregated sum might be a custom type and not int? Or maybe you have suggestion how to do a workaround.

  2. I’ve tried to apply filters to aggregation, i.e. if i will make a number of separate queries with filter & grouping then the sum still might be within the int. But when i apply filters, aggregation always returns empty results.
    If i apply the same filter to the normal query (not aggregated), then it works just fine.


Thank you for reporting to the community :slightly_smiling_face:

It seems like we have some work to do in regards to aggregation in GraphQL.
I have registered a challenge for both the u32 limitation and the bug with filtering on enums of type Integer. It still seems like filtering on Enums of type String and Auto still works.