Forum Discussion
mork
Helper V
10 years agoCreate column with true/false for previous month
Hello, I have a column with dates in the following format: d/m/yyyy How can I create a calculated column that has as values true for every entry that is on the previous month and false for t...
Quis
4 years agoNew Member
The posted soltion does not work over multiple years:
Use:
IsLastMonth = IF (
(
('Dim Date'[Year] = YEAR ( NOW () ) && MONTH ( 'Dim Date'[Date] ) = MONTH ( NOW () ) - 1) ||
(Month('Dim Date'[Date]) = 12 && Month(now()) == 1 && Year('Dim Date'[Date]) = Year(now()) - 1)), TRUE(), FALSE()
)
chestercas
Helper I
3 years agoHi,
Thank you for help !!! this is work !
But I want to do the same thing, but on the 3 last month (included the last year). I test many things but doesn't work. Can you help me ?
Thank you ! 🙂