Data Slice Row Filter THIS MONTH (Name) Expression

I have a column generated called โ€œMONTHโ€ in my data which calculates the month name from the date. This is done on google sheets table side.

In my SLICE, what is the expression to find the current month name? Iโ€™d like to set the Row Filter as:

[MONTH] = thismonth name.

Thanks!
Tony

0 6 1,728
6 REPLIES 6

Steve
Platinum 4
Platinum 4

Hi Steve,
Thanks for linking to that.

To return the the current month, would it not be:

[MONTH] = TEXT(MONTH(TODAY()), MMMM)

So that

[Month] = โ€œJUNEโ€

I know this isnโ€™t working on my expression builder but thought Iโ€™d ask you.

Nope; all you need is TEXT(TODAY(), "MMMM").

Hi Steve,
Thanks.

Iโ€™m also interested in how to express a date range in the row filter. For example, the range would be everything from the beginning of the month to TODAY().

Tried to find articles but maybe Iโ€™m not searching for the correct thing.
Thanks

Easy enough! See if the following get you anywhere. If you canโ€™t figure it out ,let us know what youโ€™ve tried and weโ€™ll get it working for you!




Steve
Platinum 4
Platinum 4

MONTH([your column name]) gives the number of the month (1โ€ฆ12) represented by the given date.

Subtracting a number from a date adjusts the date back by that number of days.

So (TODAY() - MONTH([your column name]) really doesnโ€™t give you anything meaningful.

The DAY() function, though, gives the day-of-the-month of the given date. If we subtract the day-of-the-month from the date, we get the date of the last day of the previous month:

(TODAY() - DAY(TODAY()))

We could also use the EOMONTH() function to do the same thing:

EOMONTH(TODAY(), -1)

To ask the question, โ€œdoes the date in a column fall between the beginning of the month and today?โ€:

AND(
  ([date-column] > (TODAY() - DAY(TODAY()))),
  ([date-column] <= TODAY())
)

or:

AND(
  ([date-column] > EOMONTH(TODAY(), -1)),
  ([date-column] <= TODAY())
)
Top Labels in this Space