Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

DAX - Date variable with blanks

I will try to explain in the best way possible what I need. So basically I have a calculated column from two other date columns, the "Off Rail" and "Rail Arrived", and like the dates of these colum...
  • Anonymous's avatar
    Anonymous
    2 years ago

    So I tried but it still didn't solve the problem of the same dates, but your idea helped me to implement this new formula, I run some tests and apparently it is working now, thanks for the help tamerj1 

     

    RAIL ARVD > OFF RAIL =

    VAR SEBLANK = IF(
                    ISBLANK(Plan[Rail Arrived]), "CHECK",
                    "OK"
                    )

    VAR SEDATA = IF(
                    INT(DATEDIFF(Plan[Rail Arrived], Plan[Off Rail],DAY)) > 1, "CHECK",
                    "OK"
                   )

    VAR FINAL = IF(
                    OR(SEBLANK = "CHECK", SEDATA = "CHECK"),
                    "CHECK", "OK"
                  )
                     
    RETURN
    FINAL