Hello,
I would like to add a table to my Dashboard containing a bunch of GroupedBy results. However, I'd also like to have some fields in the table that are not currently in the GroupedBy expression. I guess they could be added to the GroupedBy and still make sense, but I don't have a Statistic for them as it would be 'username' and 'date' etc., and I don't know how to write them into the grouped by without a statistic.
Also, once the table is added to Dashboard, is it possible to assign an Action to zoom to feature in map when a row is selected in the table?
Thank you!!!
Melissa
Solved! Go to Solution.
You can kind of do this. By adding your extra fields to the "groupby fields" parameter, you'll get your data grouped per stand / user / date combination.
GroupBy(
your_featureset,
['Stand_number', 'username', 'date_field'],
[{your statistic expressions}]
)
To retain geometry, though, that can't be done unless you use a loop.
I don't believe you can have an expression where some fields are grouped and others are not. I know you can't do this in SQL. The underlying set theory doesn't make it possible. All fields have to be aggregated in some way. Since the Group By returns a single result per field, it doesn't make sense to then also have a field(s) that contain multiple values.
You can (potentially) perform aggregation on fields within a record in the SELECT clause, e.g. averaging the sum of three numeric fields, and include other fields, but not across records.
You can kind of do this. By adding your extra fields to the "groupby fields" parameter, you'll get your data grouped per stand / user / date combination.
GroupBy(
your_featureset,
['Stand_number', 'username', 'date_field'],
[{your statistic expressions}]
)
To retain geometry, though, that can't be done unless you use a loop.