One of our application have entitlements formed as 'location':'role', so location is resource & role is action.
Location wise separate groups are collected, for approval & fulfillment.
In workflow I have a SQL node which compares location name and accordingly I am capturing group name. Next to that I have one more SQL node which captures all group members user id in one variable. I am passing this variable containing user id's to approval node & separately for fulfillment node.
Problem is - when multiple entitlements needs to be selected, I have marked approval & fulfillment workflow to create separate job for individual job.
So I am expecting each entitlement will create separate job and each separate job will maintain it's own job level variables.
So all entitlements should go to different different groups for approval or fulfillment.
But for all such requests none of the variables are resolving to correct members but same if I try for single entitlement then everything works fine.
This is all because I think even for separate jobs a single job level variable is being maintained and getting overwritten for each separate run. Please help me to resolve this problem.
Screen for individual entitlement -
When single entitlement is selected,
GRP_NAME return one group name and later other node returns MEM_ID - user id's of group members.
But if I select 2 entitlements then GRP_NAME variable gets appended with 2 group names.
Due to which MEM_ID is not able to return member user id's.
Anyone can suggest a different method to overcome this problem.
Thank you.
Hi Boris,
I have found my mistake, yesterday my brain wasn't working as I spent a lot of time on this.
My previous query to get the group name was based on pv_change_request_detail where I was using case statement to compare resource name and respectively returning group name.
Today as i started fresh I understood if any request is submitted with multiple entitlements, pv_change_request_detail will have those many rows with respect to a specific change request id. So I have replaced that with '${access_request_cri_ent_resourceName}' to compare.
select case
when resource_name in ('Bridgeview IL','High Point NC','Miami FL','Mobile AL',
'Round Rock TX','San Antonio TX','Spokane WA','Tempe AZ','Tucson AZ','West Hills CA','Winter Park FL')
and action_name like '%User Admin Role' then 'myacc-User Admin Role-appr'
when resource_name in ('Bridgeview IL','High Point NC','Miami FL','Mobile AL','San Antonio TX','Spokane WA','Tempe AZ',
'West Hills CA','Winter Park FL')
and action_name not like '%User Admin Role' then 'myacc-'||resource_name||'-appr'
when resource_name in ('247 Vendor','Lake Mary FL','Sitel Bogota','Sitel Manila',
'TeleTech Vendor','West Hills CA Cellphone','Des Moines IA') then 'myacc-'||resource_name||'-appr'
when resource_name like 'Other%' and action_name like '%Parts and%' then 'myacc-Other Parts and Repair-appr'
when resource_name like 'Other%' and action_name not like '%Parts and%' then 'myacc-Other-appr'
when resource_name like 'Round Rock TX' and action_name like '%Parts Re%' then 'myacc-Round Rock TX Parts Research-appr'
when resource_name like 'Round Rock TX' and (action_name not like '%User Admin Role' or action_name not like '%Parts Re%') then 'myacc-Round Rock TX-appr'
when resource_name like 'Tucson AZ' and (action_name not like '%User Admin Role' or action_name not like '%7701%') then 'myacc-Tucson AZ-appr'
when resource_name like 'Tucson AZ' and (action_name not like '%User Admin Role' or action_name like '%7701%') then 'myacc-Tucson AZ 7701-appr'
else 'NA'
end as grp_name
from t_av_change_request_details where value_type='ET' and
change_requests_id='${access_request_requestID}'
select case
when '${access_request_cri_ent_resourceName}' in ('Bridgeview IL','High Point NC','Miami FL','Mobile AL',
'Round Rock TX','San Antonio TX','Spokane WA','Tempe AZ','Tucson AZ','West Hills CA','Winter Park FL')
and '${access_request_cri_ent_action}' like '%User Admin Role' then 'myacc-User Admin Role-appr'
when '${access_request_cri_ent_resourceName}' in ('Bridgeview IL','High Point NC','Miami FL','Mobile AL','San Antonio TX','Spokane WA','Tempe AZ',
'West Hills CA','Winter Park FL')
and '${access_request_cri_ent_action}' not like '%User Admin Role' then 'myacc-'||'${access_request_cri_ent_resourceName}'||'-appr'
when '${access_request_cri_ent_resourceName}' in ('247 Vendor','Lake Mary FL','Sitel Bogota','Sitel Manila',
'TeleTech Vendor','West Hills CA Cellphone','Des Moines IA') then 'myacc-'||'${access_request_cri_ent_resourceName}'||'-appr'
when '${access_request_cri_ent_resourceName}' like 'Other%' and '${access_request_cri_ent_action}' like '%Parts and%' then 'myacc-Other Parts and Repair-appr'
when '${access_request_cri_ent_resourceName}' like 'Other%' and '${access_request_cri_ent_action}' not like '%Parts and%' then 'myacc-Other-appr'
when '${access_request_cri_ent_resourceName}' like 'Round Rock TX' and '${access_request_cri_ent_action}' like '%Parts Re%' then 'myacc-Round Rock TX Parts Research-appr'
when '${access_request_cri_ent_resourceName}' like 'Round Rock TX' and ('${access_request_cri_ent_action}' not like '%User Admin Role' or '${access_request_cri_ent_action}' not like '%Parts Re%') then 'myacc-Round Rock TX-appr'
when '${access_request_cri_ent_resourceName}' like 'Tucson AZ' and ('${access_request_cri_ent_action}' not like '%User Admin Role' or '${access_request_cri_ent_action}' not like '%7701%') then 'myacc-Tucson AZ-appr'
when '${access_request_cri_ent_resourceName}' like 'Tucson AZ' and ('${access_request_cri_ent_action}' not like '%User Admin Role' or '${access_request_cri_ent_action}' like '%7701%') then 'myacc-Tucson AZ 7701-appr'
else 'NA'
end as grp_name
from dual