Forum Discussion
Lobs
Helper II
5 years agoPrevious Month Segment
Hi All, Im trying to get a value coming from the previous month on the same table, I tried the following, but always got blank results. PM Segment = CALCULATE ( FIRSTNONBLANK(Roster[Se...
- 5 years ago
Hi Lobs ,
FILTER ( ALL ( Roster ), Roster[IDFDATE]= Roster[IDPMFDATE] )
The problem may be in this filter condition.
Please try this:
Column = CALCULATE(FIRSTNONBLANK(Roster[Segments_],1),FILTER(Roster,EARLIER(Roster[IDFDATE])=Roster[IDFDATE]&&Roster[IDPMFDATE] IN VALUES(Roster[IDFDATE])))If segment is obtained by month, create two columns respectively to represent the current month and previous month, and the formula is similar to the above.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
V-lianl-msft
Community Support
5 years agoHi Lobs ,
FILTER ( ALL ( Roster ), Roster[IDFDATE]= Roster[IDPMFDATE] )
The problem may be in this filter condition.
Please try this:
Column = CALCULATE(FIRSTNONBLANK(Roster[Segments_],1),FILTER(Roster,EARLIER(Roster[IDFDATE])=Roster[IDFDATE]&&Roster[IDPMFDATE] IN VALUES(Roster[IDFDATE])))If segment is obtained by month, create two columns respectively to represent the current month and previous month, and the formula is similar to the above.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.