Solved

What is the best way to compare workflow current date and a datetime column in a list?

  • 13 December 2022
  • 2 replies
  • 666 views

Badge +2

I love to compare two DateTime dates in my workflow

icon

Best answer by Garrett 13 December 2022, 17:13

View original

2 replies

Userlevel 6
Badge +16

Hi @Messam 

 

You can use either the Run-If or the Conditional Branch action to compare Datetimes.

You can compare with the Greater Than (>) or the Lesser Than (<) operator.

 

Comparing for Equality (==) requires a little more effort. Equality comparison will always fail. While the date are the same, the time are different. Convert the Datetimes value into a Short Date or Long Date String. Use a Build String action on a DateTime variable.
Once converted into String type, you should be able to compare for Equality.

 

Hope that helps

Badge +2

Thanks very much. The time difference was really a big issue for me for me.

 

Reply