Forum Discussion
DBrito79
2 years agoFrequent Visitor
Find first values per earliest Date
Hello, I have a table called "Cycles" and i need a dax column with the value (the name) of CYCLES[Status Atual] for the earlier/maximum [FirstMatingDate] and for each CYCLES[ID&FARM] I am trying ...
- Anonymous2 years ago
HI DBrito79,
You can try to use the following measure formula if it suitable for your requirement:
EarliestStatusAtFirstMatingDate = VAR _lastDate = CALCULATE ( MAX ( CYCLES[FirstMatingDate] ), ALLSELECTED ( CYCLES ), VALUES ( CYCLES[ID&FARM] ) ) RETURN CALCULATE ( MAX ( CYCLES[Status Atual] ), FILTER ( ALLSELECTED ( CYCLES ), CYCLES[FirstMatingDate] = _lastDate ) )Regards,
Xiaoxin Sheng
Anonymous
2 years agoNot applicable
HI DBrito79,
You can try to use the following measure formula if it suitable for your requirement:
EarliestStatusAtFirstMatingDate =
VAR _lastDate =
CALCULATE (
MAX ( CYCLES[FirstMatingDate] ),
ALLSELECTED ( CYCLES ),
VALUES ( CYCLES[ID&FARM] )
)
RETURN
CALCULATE (
MAX ( CYCLES[Status Atual] ),
FILTER ( ALLSELECTED ( CYCLES ), CYCLES[FirstMatingDate] = _lastDate )
)
Regards,
Xiaoxin Sheng
- DBrito792 years agoFrequent Visitor
It worked... Thanks a million, Sorry for the delay ansewring . Regards