Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Dynamic attribute in SQL concat query

tanvi_gaikwad
New Contributor II
New Contributor II

Hello, 

We are creating a Create User Form having dynamic attributes. mpe_username, mpe_surname and dealernet_id_number.

We need dealernet_id_number as "002[mpe_username][mpe_surname]".

We have tried select concat('002', ${mpe_givenname},${mpe_surname}) as ID

but that does not populate the value in required customproperty and it remains empty after user is created.

Referring to solution provided at Solved: Create User form - Populating an attribute value b... - Saviynt Forums - 55612.

Assistance required.

16 REPLIES 16

Shreya-B
New Contributor
New Contributor

Hi ,

Please try with:

1. Parent Dynamic attributes: mpe_givenname and mpe_surname

What action to perform when Parent attribute changes?: Refresh for both

 

2. Child Dynamic attribute :  dealernet_id_number

select concat('002',${mpe_givenname},${mpe_surname}) as ID

ShreyaB_1-1707167273918.png

 

ShreyaB_0-1707167211509.png

 

rushikeshvartak
All-Star
All-Star

Share dynamic attributes configs


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

tanvi_gaikwad
New Contributor II
New Contributor II

Hello Shreya, thanks for the reply. We have been using the same configuration as you have suggested. Still it does not work. Sharing the screenshots of the config.

These attributes are level 2 and level 3 dependency hierarchy. Another attribute 'usertype' is the main DA on which these are depended.

usertyoe->mpe_firstname,mpe_lastname -> dealernet_id_number. 

We are using action string in the usertype to SHOW/HIDE these attributes.

Share screenshot


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

Try by using just 1 attribute as parent.

tanvi_gaikwad
New Contributor II
New Contributor II

We have been trying single attribute as parent. Not working.

can you share a more detailed screenshot of all DAs used.

tanvi_gaikwad
New Contributor II
New Contributor II

There are around 50 DA. I can share the action string if that helps

 

Provide impacted 3 DAs


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

tanvi_gaikwad
New Contributor II
New Contributor II

We have 3 different user types - AUH Dealer, Internal User, MPE Dealer. Below is the action string for the above 3 attributes.

 

HIDE###mpe_givenname###Please select user type___HIDE###mpe_surname###Please select user type___HIDE###dealernet_id_number###Please select user type___HIDE###mpe_givenname###AUH Dealer___HIDE###mpe_surname###AUH Dealer___HIDE###dealernet_id_number###AUH Dealer___HIDE###mpe_givenname###Internal User___HIDE###mpe_surname###Internal User___HIDE###dealernet_id_number###Internal User___SHOW###mpe_givenname###MPE Dealer___SHOW###mpe_surname###MPE Dealer___SHOW###dealernet_id_number###MPE Dealer___REQ###mpe_givenname###MPE Dealer___REQ###mpe_surname###MPE Dealer___NREQ###dealernet_id_number###MPE Dealer___

tanvi_gaikwad
New Contributor II
New Contributor II

Hello Shreya and Rushikesh, 

I have a simpler usercase.

Created 2 attributes - samplefn (parent) and sampleid (child). Attached is the screenshot for the configurations of these attributes. Also attached is the result on UI where no records are shown in the dropdown.

samplefn - String

sampleid - Single select from SQL Query - select ${samplefn} as ID;

Below are the logs for this issue.

2024-02-08T08:51:43+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2342-2hd84-DEBUG-Inside getSelect2DataforDAJson
 
2024-02-08T08:51:43+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2342-2hd84-DEBUG-finalQuery--select ID as ID from (select '' as ID) as T order by ID
 
2024-02-08T08:51:43+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2342-2hd84-DEBUG-jsonProduct--[results:[], total:1]
 
2024-02-08T08:51:32+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2292-2hd84-DEBUG-Inside getSelect2DataforDAJson
 
2024-02-08T08:51:32+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2292-2hd84-DEBUG-finalQuery--select ID as ID from (select '' as ID) as T order by ID
 
2024-02-08T08:51:32+05:30-ecm-workflow.JbpmworkflowmanagementController-http-nio-8080-exec-2292-2hd84-DEBUG-jsonProduct--[results:[], total:1]

Please assist to resolve.

You can't use mapping on String attribute type

Refer https://forums.saviynt.com/t5/saviynt-knowledge-base/configuring-create-register-user-form-in-eic/ta...


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

tanvi_gaikwad
New Contributor II
New Contributor II

We tried this approach. It needs a extra trigger attribute which will trigger the child attribute when the parent attribute is changed. Is there any way we can eliminate the trigger attribute ?

No 

You can't use mapping on String attribute type


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

Can we use mapping on Enum or Boolean kind of data types?

You can use 


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