Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Dynamic Previous Month Column

Hi,   I have included a picture of the table below that I'm working with. Essentialy what I want is a Column that says "TRUE" when it is the previous month dynamically and "FALSE" when it isnt. I c...
  • v-janeyg-msft's avatar
    5 years ago

    Hi, Anonymous 

     

    According to your description,I think you can create a measure or column to calculate the desired result.

    Like this:

    Column = var month1=MONTH(EDATE(TODAY(),-1))
    var month2=MONTH('Table'[date])
    return IF(month1=month2,"True","False")
    Measure = var month1=MONTH(EDATE(TODAY(),-1))
    var month2=MONTH(SELECTEDVALUE('Table'[date]))
    return IF(month1=month2,"True","False")

    If it doesn’t solve your problem, please feel free to ask me.

     

    Best Regards

    Janey Guo

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.