We are delighted to share our new EIC Delivery Methodology for efficiently managing Saviynt Implementations and delivering quick time to value. CLICK HERE.

Create User Form | Child Attribute is not auto populating

draut
New Contributor III
New Contributor III

Hi Team,

We have configured a child attribute displayname in the Register User Form with the help of concat(${lastname},'  ',${firstname}) but the display name attribute is not auto-populating.

Screenshot 2024-01-11 140841.pngScreenshot 2024-01-11 140910.pngScreenshot 2024-01-11 140933.pngScreenshot 2024-01-11 141014.png

 

Query : select distinct concat(lastname," ",firstname) as ID from users where username=${username}

Screenshot 2024-01-11 140759.png

Dheeraj
23 REPLIES 23

Dhruv_Sharma
Saviynt Employee
Saviynt Employee

Hi @draut 

Please confirm if the same query is giving results in data analyzer with hardcoded username. 

Also please check the error message in the logs at the time of opening create user page.

Regards,

Dhruv Sharma

draut
New Contributor III
New Contributor III

Not sure how it will give the result in the data analyzer since the user record is not present yet, I will check the logs.

Dheeraj

draut
New Contributor III
New Contributor III

2024-01-11T15:13:51+05:30-ecm-2024-01-11T09:43:51.236042137Z stdout F 2024-01-11 09:43:51,235 [http-nio-8080-exec-5] DEBUG workflow.JbpmworkflowmanagementController - finalQuery--select ID as ID from (select distinct concat(lastname," ",firstname) as ID from users where username='F0000209') as T order by ID

Dheeraj

It might be throwing an error in the logs post this query is executed. Can you check and share that error.

draut
New Contributor III
New Contributor III

It does not give any error, got just the above message

Dheeraj

draut
New Contributor III
New Contributor III

If you suggest any other query to populate the display name using firstname and lastname please provide

Dheeraj

Share full dynamic attribute screenshot for first name & last name


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

draut
New Contributor III
New Contributor III

firstname.pngfirstname_1.pngfirstname_2.png

Lastname :

lastname.pnglastname_1.pnglastname_2.png

Dheeraj

Hi @draut 

1. Displayname is being calculated based on the dynamic value of username, hence you should use username as the parent attribute in displayname attribute. However you have kept lastname as parent attribute. 

2. In the lastname attribute, there is no parent attribute hence you should not use Refresh there.

Please try once post correcting these two and let me know the results. 

Regards,

Dhruv Sharma

 

draut
New Contributor III
New Contributor III

I updated the configuration but got same message "No Match Found "

DEBUG workflow.JbpmworkflowmanagementController - finalQuery--select ID as ID from (select distinct concat(lastname," , ",firstname) as ID from users where username='F0000210') as T order by ID

Dheeraj

use Mapping instead of refresh


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

Tried but it's not working

 

Dheeraj

check https://forums.saviynt.com/t5/general-discussions/is-there-a-way-to-generate-display-name-as-part-of... 


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

Hi @draut 

From the logs, I can see that it is executing like below.

finalQuery--select ID as ID from (select distinct concat(lastname," , ",firstname) as ID from users where username='F0000210') as T order by ID

However, when the user is being created newly, firstname and lastname is also being fetched dynamically hence please try with ${firstname} and ${lastname} in the query and see if it works. Please share the logs when query is executed.

Regards,

Dhruv Sharma

Hi @rushikeshvartak ,

Thanks for the suggestion.

Can you please confirm, if I am using correct syntax

Value : select concat('${firstname}'',''${lastname}') as ID

Validation : ${displayname==(firstname+' '+lastname)}

 

Screenshot 2024-01-16 181430.pngScreenshot 2024-01-16 181511.png

Dheeraj

Yes. Can you keep dynamic attributes name different ( add dyn in start)


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

Hi @draut 

As suggested previously, could you please try with ${firstname} and ${lastname} in the query instead of firstname and lastname and confirm if it works.

Regards,

Dhruv Sharma

Mapping does not work in String Attribute Type


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

mohitarora1
New Contributor III
New Contributor III

@draut Firstname and lastname are String type of attributes, hence it is not generating event for the child attribute displayname to get triggered. Here is how we have achieved this, we created another dynamic attribute of Sql Enum Type with query Select 'Yes' as ID concat Select 'Regenerate On Name Change' as ID  and mapped this as a parent of displayname.

Thanks,

Mohit Arora

mohitarora1
New Contributor III
New Contributor III

Correct Query we have used: select 'Yes' as ID union select 'Regenerate on Name Change' as ID

 

 

mohitarora1_0-1705428863771.pngmohitarora1_1-1705428894694.png

 

mohitarora1_2-1705428922026.png

Thanks,

Mohit Arora

draut
New Contributor III
New Contributor III

Hi @mohitarora1 ,

Thanks for the reply, will try this.

Regards,

Dheeraj

Dheeraj

draut
New Contributor III
New Contributor III

Hi @mohitarora1 

Thanks, it worked,

Used this query as per my need.

SELECT CONCAT(${lastname},',', ${firstname}) AS ID

Regards,

Dheeraj

Dheeraj

mohitarora1
New Contributor III
New Contributor III

@draut If you find the response useful, kindly consider selecting Accept As Solution

Thanks,

Mohit Arora