cube-js/cube

inDateRange with only one date not working as expected

Offen

#3.111 geöffnet am 15.07.2021

 (4 Kommentare) (1 Reaktion) (1 zugewiesene Person)Rust (1.965 Forks)batch import
api:resthelp wanted

Repository-Metriken

Stars
 (19.563 Sterne)
PR-Merge-Metriken
 (PR-Metriken ausstehend)

Beschreibung

Describe the bug As stated in the documentation (operator inDateRange) "If only one date specified the filter would be set exactly to this date". Instead, it seems to consider the only date provided as a lower bound.

To Reproduce

{
  member: "Posts.time",
  operator: "inDateRange",
  values: ['2015-01-01']
}

Expected behavior Same as

{
  member: "Posts.time",
  operator: "inDateRange",
  values: ['2015-01-01', '2015-01-01']
}

or

{
  member: "Posts.time",
  operator: "equals",
  values: ['2015-01-01']
}

Version: 0.26.77

Contributor Guide