Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[FEATURE] Add order by support to expression aggregate and concatenat…
…ion functions Because certain aggregates and concatenation requires results in a certain order, this change allows specific control of the order features are added to the aggregate during an expression evaluation. E.g. concatenate("Station",concatenator:=',', order_by:="Station") will give a comma separated list of station names in alphabetical order, rather than layer feature order. Sponsored by SMEC/SJ
- Loading branch information
1 parent
6b16218
commit 2e52573
Showing
7 changed files
with
112 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"name": "concatenate_unique", | ||
"type": "function", | ||
"description": "Returns all unique strings from a field or expression joined by a delimiter.", | ||
"arguments": [ | ||
{"arg":"expression", "description":"sub expression of field to aggregate"}, | ||
{"arg":"group_by", "optional":true, "description":"optional expression to use to group aggregate calculations"}, | ||
{"arg":"filter", "optional":true, "description":"optional expression to use to filter features used to calculate aggregate"}, | ||
{"arg":"concatenator", "optional":true, "description":"optional string to use to join values"}, | ||
{"arg":"order_by", "optional":true, "description":"optional expression to use to order features used to calculate aggregate"} | ||
], | ||
"examples": [ | ||
{ "expression":"concatenate(\"town_name\",group_by:=\"state\",concatenator:=',')", "returns":"comma separated list of unique town_names, grouped by state field"} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.