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

System Username Generation Rule With Condition

harish14
New Contributor
New Contributor

Hello Team,

We have a requirement where we need to generate system username by using below 2 cases:

Case -1 : For contractors the logic should be user's title + customproperty2

Example - user's title + customproperty2  (MD1234)

Case -2 : For Employees the logic should be 'ABCD' + users.username

Example - ABCD + users.username (ABCD1234)

When I try to use below logic it's throwing an error

logic - select case when (users.employeeType)='Contractor' then (concat(users.title),(users.customproperty2))else (concat('ABCD',users.username))end###

1 REPLY 1

jayasudha
Saviynt Employee
Saviynt Employee

Hi Harish,

Could you please test the below query. Please make sure you are entering all the required fields.

jayasudha_0-1662357461025.png

if ((users.employeeType)='Contractor',(concat(users.title,users.customproperty2)), (concat('ABCD',users.username)))

If it is not working, Could you please share the logs with us.

Thanks and regards,

Jayasudha R