Click HERE to see how Saviynt Intelligence is transforming the industry. |
09/11/2024 06:58 AM
Hi Team
There is requirement to check if user email exists in saviynt or not.
User will add owner email in the form which is a dynamic attribute - Approver. We need to validate if approver is valid email else auto reject. I have tries below query it is not working.
(com.saviynt.ecm.identitywarehouse.domain.Users.executeQuery("select u.id from users u where u.email= '${Approver}'").size()== 1)
09/11/2024 07:05 AM - edited 09/11/2024 07:07 AM
@Jayati1 use
(dynamicAttributes.get('Approver')
09/11/2024 07:07 AM
yes tried this also and tried to hard-code the value as well
09/11/2024 07:10 AM
@Jayati1 language selected in if else block groovy right?
09/11/2024 07:13 AM
yes , selected groovy
09/11/2024 07:17 AM
@Jayati1 can you share logs in text file.
09/11/2024 07:26 AM
09/11/2024 07:32 AM
@Jayati1 doesn't seem to find relevant log .. can you process a request and share the logs
09/11/2024 07:33 AM
i dont see anything specific in logs. I can share again
09/11/2024 07:34 AM
Yess.
09/11/2024 07:41 AM
Share workflow Wiring
09/11/2024 07:55 AM
09/11/2024 08:12 AM
Can you share data analyzer value for Approver from request_access_attrs table
09/11/2024 08:11 AM
Hi @rushikeshvartak - can you please help.
09/11/2024 08:20 AM
its a dynamic attribute which stores email
09/11/2024 08:21 AM
09/11/2024 08:23 AM
You can create another dynamic attribute and validate if email exists in users table or not. and then use DA2 in workflow
09/11/2024 08:50 AM
I tried this workflow is still not working
09/11/2024 08:53 AM
Share all configuration and validation screenshot and logs in word doc
@Jayati1 When you pasting image make sure it made large refer https://forums.saviynt.com/t5/forum-feedback/enlarge-image-by-default/m-p/96947
09/11/2024 08:57 AM
sure. Can you please confirm if below query is correct in workflow if -else block. because it works as expected without this block.
(com.saviynt.ecm.identitywarehouse.domain.Users.executeQuery("select u.id from Users u where u.email='${da3}'").size()==1)
09/11/2024 08:59 AM
You dont need groovy block
09/11/2024 09:02 AM
this block is required to check if value provided by user in da3 exist in user table or not
09/11/2024 09:22 AM
@Jayati1 userkey in the query is static value how are you fetching it.
You don't need userkey .. email checking is enough
09/11/2024 09:25 AM
09/11/2024 09:25 AM
i tried this also-
(com.saviynt.ecm.identitywarehouse.domain.Users.executeQuery("select u.id from users u where u.email='${da3}'").size() eq 0)
(com.saviynt.ecm.identitywarehouse.domain.Users.executeQuery("select count(u.id) from users u where u.email='${da3}'").size() eq 0)
(com.saviynt.ecm.identitywarehouse.domain.Users.executeQuery("select count(u.userkey) from users u where u.email='${da3}'").size() eq 0)
09/11/2024 11:55 AM
DA1- Email -String
DA2-Single select from sql query -select 'Yes' as ID from users u where u.email=${DA1}
} parent attribute-DA1,Action-Mapping
This mapping is not working
09/11/2024 11:57 AM
Share config screenshot
09/11/2024 11:58 AM - edited 09/11/2024 11:58 AM
@Jayati1 add mapping as action in DA1 too
09/11/2024 12:09 PM
select 'Yes' as ID from users u where u.email in ('${DA1}')
09/11/2024 02:18 PM
cp28 should be in lower case
09/11/2024 01:26 PM
@Jayati1 can you also share request page screenshot does it show blank for DA2?