Click HERE to see how Saviynt Intelligence is transforming the industry. |
09/26/2024 01:46 AM
Hi Team,
our current email generation rule is configured based on internal and external users.
If user is internal then concat firstname and last name after that @internal.abc.com.
If user is external then concat firstname and last name after that @external.abc.com.
Sample query:
--------------------
case when (users.employeeType='Internal') THEN concat(users.firstname,'.',users.lastname,'@access2quadrupel.com') ELSE concat(users.firstname,'.',users.lastname,'@external.access2quadrupel.com') END
BUT we are having one more requirement where if firstname and lastname are already present then the email generate rule should create another email with increment values.
Example: sam.doe1@domain.com , sam.doe2@domain.com , sam.doe3@domain.com.
Kindly help on this
Thanks,
Saumya
09/26/2024 11:10 AM
Sample logi c
case when (users.employeeType='Internal') THEN concat(users.firstname,'.',users.lastname,'@access2quadrupel.com')
when (users.employeeType='Internal') and (username=concat(users.firstname,'.',users.lastname,'@access2quadrupel.com'))THEN concat(users.firstname,'.',users.lastname,'1@access2quadrupel.com')
when (users.employeeType='Internal') and (username=concat(users.firstname,'.',users.lastname,'@1access2quadrupel.com'))THEN concat(users.firstname,'.',users.lastname,'2@access2quadrupel.com')
when (users.employeeType='External') THEN concat(users.firstname,'.',users.lastname,'@external.access2quadrupel.com')
when (users.employeeType='External') and (username=concat(users.firstname,'.',users.lastname,'@external.access2quadrupel.com'))THEN concat(users.firstname,'.',users.lastname,'1@access2quadrupel.com')
when (users.employeeType='External') and (username=concat(users.firstname,'.',users.lastname,'@1external.access2quadrupel.com'))THEN concat(users.firstname,'.',users.lastname,'2@access2quadrupel.com')
END