Forum Discussion

Bebecirux's avatar
Bebecirux
Frequent Visitor
3 years ago
Solved

the last result

Hi olgad good afternoon I have a problem with the last fob size, it should give me the last one, but in some cases the month is repeated and then it adds them, how can I do so that it gives me only ...
  • Ahmedx's avatar
    3 years ago
    Ultimo FOB =
    VAR UltimaFechaFOB =
        CALCULATE(
            MAX(CostosXProveedor[Fecha]),
            ALL(CostosXProveedor[FOB])
        )
    
    RETURN
        CALCULATE(
            MAX(CostosXProveedor[FOB]),
            FILTER(CostosXProveedor, CostosXProveedor[Fecha] = UltimaFechaFOB
           
        ))