Select to view content in your preferred language

Statistics Query using Shape.length or Shape.area

161
0
05-07-2024 04:41 AM
Labels (1)
MarkJTurnbull
New Contributor III

Hi REST Gurus

I am looking to perform some statistics queries on layers in a feature (utility network) service to support some development with chart components. This works well with numeric attribute fields, however if I want to get stats based on the shape.length values (e.g. get total length for all linear feature in a feature layer) I find the statistics query fails. I know there are many options to pulling the geometries back and performing client side analysis to get the geometry lengths/areas and performing aggregation. The problem is some of these layers can have hundreds of thousands of features, pulling them back would be slow. So I am trying to find a function that will process the geometries server side and just return an aggregated result, which is what the statistical REST query does, except it fails for geometry attributes. I know I will get suggestions to create additional fields and use calculate field or attribute rules/arcade to populate these fields, however this will not fit with the brief as the app needs to have no dependencies upon the utility network service and require no other extension licenses. Any ideas on how to achieve this, before I start looking at developing GP services to query via database connection or SOEs/SOIs?

Thanks

0 Kudos
0 Replies