Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

Analytics query for enable account for specific time interval

ARNAB86
Regular Contributor
Regular Contributor

Hi Team,

I have a requirement below

If i want to enable the account based on user custompropery15 means if we are passing start date as 15-07-2024 in custompropery15 field.So when the currentdate matches with customproperty15 then analytics should run and based on that enable account task will get created.

Please let me know the analytic query to enable the account.

1 REPLY 1

rushikeshvartak
All-Star
All-Star

Select a.name,
a.accountkey AS acctKey,
a.endpointkey,
'enableAccount' AS Default_Action_For_Analytics
FROM
accounts a
JOIN
user_accounts ua ON a.accountkey = ua.accountkey
JOIN
users u ON ua.userkey = u.userkey
WHERE
a.lastlogondate BETWEEN '2024-01-01 00:00:00' AND '2024-12-31 23:59:59'
AND a.endpointkey = 10
AND u.customproperty15 = DATE_FORMAT(NOW(), '%d-%m-%Y')
AND a.status IN (1, 'Manually Provisioned')


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.