Can you compare two date variables in workflow editor if core activity

achen
Tera Contributor

Hello,

 

I am trying to compare two date variables in the workflow editor to see if the date is more than 30 days but it is not showing me a second variable field.  Is there any way to do this?  This is from the Core Activies > Condition > If

2 REPLIES 2

Akash4
Kilo Sage

Hello,

It depends on where the two variables are residing and on which table is the Workflow running on? Did you try using code similar to this - 

gs.dateDiff(date1, date2, true) > 30 * 24 * 60 * 60 * 1000 //(milliseconds)

Regards, Akash

Brad Bowman
Mega Patron

Not view the condition builder, but if you check the Advanced box and write a script you will have access to every variable and server-side GlideDateTime methods