We are delighted to share our new EIC Delivery Methodology for efficiently managing Saviynt Implementations and delivering quick time to value. CLICK HERE.

Date comparison in JSON

rajat1996
New Contributor III
New Contributor III

Hi, 

We are trying to compare termdate of user with current date and based on that a attribute needs to be updated. The tasks are getting completed but value in not getting privisioned. Maybe our date comparison is not running properly. 

We have tried. 

Calendar.getInstance().getTime())

current_date

currenttimestamp()

timestampdiff() - for getting date difference. 

We are also trying to print values in JSON for testing. to get to know till where our code is executing. does print statement work in update account JSON ?

 

Has anyone worked on such scenario for date comparison ?

2 REPLIES 2

DaanishJawed
Saviynt Employee
Saviynt Employee

Hi @rajat1996 ,

  • What is the connection type?
  • Please share the UpdateAccountJson that you are trying with.

Thanks.

rushikeshvartak
All-Star
All-Star

\"active\":\"${(user?.startdate.format('dd-MM-yy)'<(Calendar.instance.format('dd-MM-yy')))?'true':'false'}\"

Refer https://forums.saviynt.com/t5/identity-governance/current-date-comparison-in-rest-connector-update-a...


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.