We have a scenario wherein If a user is terminated his accounts will be disable (Disable User Account),
If the user returns to the organization within 14 days his accounts should be Enabled (Enable User Account).
Disable user Account user update rule is working as expected, we're facing issues wrt Enable user account.
We are running the following User Update Rule, but it doesn't create a Enable Account task
This gives us a successful preview with the user we intend to target and test on.
We tried to use datediff in a different format too with successful preview but it didn't create a task to Enable user account
But, when we remove the datediff function, we were able to successfully generate a task to Enable User account.
Please can you help us resolve the issue ?
Thanks and Regards,
Solved! Go to Solution.
Can you please try with the below condition.
datediff(a.enddate,now()) <= 14
There needs to be a space before and after "<=" so that the operator is saved correctly.
If you use datediff(a.enddate,now()) <=14 as shared in the screenshot, it will get saved as datediff(a.enddate,now()) <=14 and will not perform the intended operation.
Hence can you try with the suggested syntax of datediff(a.enddate,now()) <= 14
Also, users table is given the alias as a. Hence, while referencing any user attribute in user update rule use it as a.enddate, a.firstname etc.
Thank you for your valuable suggestion, we were able to run the User Update rule successfully.
But as suggested when we used alias as a (Eg: a.statuskey or a.usersource), this wasn't creating a task
Without using the alias we were able to generate the task