| Use this parameter to define an expression returning an integer, which
corresponds to the maximum number of groups that you want to get in output. The
number of groups depends on the fields (year, month, day...) enabled using the
previous parameters. For example, if you have two YYYY-MM-dd dates,
2026-01-01 and 2026-02-01:
- If you aggregate by year, you get only one
2026 group in
output.
- If you aggregate by year and month, you get two groups in output,
2026-01 and 2026-02.
When you define a Max groups parameter, the date
function begins by aggregating all the fields that you enabled. If there are more
groups in output than the number defined in Max groups, it
disables fields from the most precise to the less precise. It starts by clearing
Enable second field, and if there are still too many
groups, it clears Enable minute field, etc., until you get
fewer groups in output than the value defined in Max
groups. If there are 3 dates, 2026-01-01,
2026-02-01, and 2026-03-01, and you decide to
aggregate by months, you get 3 groups in output: 2026-01-01,
2026-02-01, and 2026-03-01. If you set
Max groups to 3, you get the same result,
but if you set it to 2, there are too many groups so the function
disables the month field and the output returns only the year group
2026. |