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

Saviynt is not replacing the less than & greater than characters (<>) in System username generation

Ajit
New Contributor III
New Contributor III

Hi Team,

We have created a query to replace all the special characters in system username and email generation logic. Saviynt is replacing all special characters but not replacing less than and greater than (<>) and it is taking as lt & gt respectively.

Below is the code we are using to replace the characters:

replace(replace(replace(replace(replace((replace(users.lastname,'@','')),'_',''),'-',''),'"',''),'.',''),'<>','')

Could you please help how we can replace these (<>) characters.

 

Thanks

5 REPLIES 5

sudeshjaiswal
Saviynt Employee
Saviynt Employee

Hello @Ajit,

Could you please try use the below function and see if it works for you,

replace(replace(replace(replace(replace((replace(replace(users.lastname,'<',''),'>','')),'@','')),'_',''),'-',''),'"',''),'.','')
Thanks.
If you find the above response useful, Kindly Mark it as "Accept As Solution".

Ajit
New Contributor III
New Contributor III

Hi @sudeshjaiswal ,

Thanks for the response, tried but it's not generating the system username, and also tried with below code but still the issue is same

replace(replace(replace(replace(replace(replace((replace(users.lastname,'<','')),'>',''),'-',''),'"',''),'.',''),'@',''),'_','')

 

sudeshjaiswal
Saviynt Employee
Saviynt Employee

Hello @Ajit,

Can you please try using the translate function in the query:
replace(replace(replace(replace(replace(replace((replace(users.lastname,'@','')),'_',''),'-',''),'"',''),'.',''), TRANSLATE(users.lastname, '<>', ''),'')


Also please traced the logs and share the log snippet.

Thanks.


If you find the above response useful, Kindly Mark it as "Accept As Solution".

Ajit
New Contributor III
New Contributor III

Hi @sudeshjaiswal ,

Please find the code we tried:

concat(replace(replace(replace(replace(replace((replace(users.lastname,'@','')),'_',''),'-',''),'"',''),'.',''), TRANSLATE(users.lastname, '<>', ''),''), replace(replace(replace(replace((replace((SUBSTRING(users.firstname,1,1)),'@','')),'_',''),'-',''),'"',''),'.',''), '@xyz.com')

Error in the logs:

Ajit_0-1700041753143.png

Please let us know if we are missing anything.

Thanks

sudeshjaiswal
Saviynt Employee
Saviynt Employee

Hello @Ajit,

Did you try to use the same in Modifyuserdatajson during import instead of system username generation rule.

Thanks

If you find the above response useful, Kindly Mark it as "Accept As Solution".