Repository navigation
ESQL: support for buckets larger than 1 year #120094
Copy link
Copy link
Closed
Labels
:Analytics/ES|QLAKA ESQLAKA ESQL>enhancementTeam:AnalyticsMeta label for analytical engine team (ESQL/Aggs/Geo)Meta label for analytical engine team (ESQL/Aggs/Geo)
Description
Activity
elasticsearchmachine commented
on Jan 14, 2025 CollaboratorMore actionsPinging @elastic/es-analytical-engine (Team:Analytics)
- addedTeam:AnalyticsMeta label for analytical engine team (ESQL/Aggs/Geo)Meta label for analytical engine team (ESQL/Aggs/Geo)
on Jan 14, 2025 Same applies to DATE_TRUNC (which BUCKET makes use of internally).
Hi @bpintea , I would like to address this issue🙂.
My first thought is to add a
cardinalparameter inroundFloorto indicate the interval as a multiple of this datetime unit.
elasticsearch/server/src/main/java/org/elasticsearch/common/Rounding.java
Lines 170 to 177 in a59c182
/** * This rounds down the supplied milliseconds since the epoch down to the next unit. In order to retain performance this method * should be as fast as possible and not try to convert dates to java-time objects if possible * * @param utcMillis the milliseconds since the epoch * @return the rounded down milliseconds since the epoch */ abstract long roundFloor(long utcMillis); - added a commit that references this issue
on Apr 3, 2025 - added a commit that references this issue
on Apr 9, 2025 - added 2 commits that reference this issue
on Jun 18, 2025
Metadata
Metadata
Assignees
Labels
:Analytics/ES|QLAKA ESQLAKA ESQL>enhancementTeam:AnalyticsMeta label for analytical engine team (ESQL/Aggs/Geo)Meta label for analytical engine team (ESQL/Aggs/Geo)
Description
Currently, when BUCKETing, the time interval expressed in years cannot be larger than 1. However, specifying the interval in weeks allows for an arbitrary number. This issue is to look into removing the year restriction (or any other seemingly arbitrary ones)