Announcing the SAVIYNT KNOWLEDGE EXCHANGE unifying the Saviynt forums, documentation, training, and more in a single search tool across platforms. Click HERE to read the Announcement.

How to use dynamic attribute in ACCOUNTNAMERULE

Naveen_Talanos
Regular Contributor
Regular Contributor

Hi Experts,

Please help

We have created a dynamic attribute to use it in Service Account Form. I want users to pick value from this field and I want the selected value to be part of ACCOUNTNAMERULE in connection.

Naveen_Talanos_0-1670246322734.png

1. How do I use it in ACCOUNTNAMERULE? Below is the rule I use and highlighted is where I want the value to Dynamic Attribute.

${if (ServiceAccountOwnerMap.ServiceAccountType.equals('Service Account')) {'CN='+task.accountName+',OU='+${account.customproperty40}+',OU=Applications,DC=company,DC=local'} else {'CN='+user.username+',OU='+user.departmentNumber+',OU='+user.departmentname+',OU=Accounts,DC=company,DC=local'}}

2. How do I create this dynamic attribute as dropdown, where do I define dropdown values?

Please help

Regards,

Naveen

7 REPLIES 7

Naveen_Talanos
Regular Contributor
Regular Contributor

rushikeshvartak
All-Star
All-Star

Customproperty40 should be lower case


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

Thanks @rushikeshvartak for the reply.

But I am getting below error:

Error while creating account in AD - No such property: customproperty40 for class: java.lang.String

I did change "Accounts column" to lower case.

Naveen_Talanos_0-1670284728063.png

This is my "ACCOUNTNAMERULE"

${if (ServiceAccountOwnerMap.ServiceAccountType.equals('Service Account')) {'CN='+task.accountName+',OU='+account.customproperty40+',OU=Applications,DC=company,DC=local'} else {'CN='+user.username+',OU='+user.departmentNumber+',OU='+user.departmentname+',OU=Accounts,DC=company,DC=local'}}

Just wondering if it is the correct way to use the value to dynamic attribute...

Just to put it again, dynamic attribute "ApplicationName" is being populated in the form while capturing details of Service Account.

Please guide

Regards,

Naveen

task.accountKey.customproperty40


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

Another error 😞

Error while creating account in AD - Cannot get property 'customproperty40' on null object

${if (ServiceAccountOwnerMap.ServiceAccountType.equals('Service Account')) {'CN='+task.accountName+',OU='+ApplicationName+',OU=Applications,DC=talanos,DC=local'} else {'CN='+user.username+',OU='+user.departmentNumber+',OU='+user.departmentname+',OU=Accounts,DC=talanos,DC=local'}}


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

Sometimes the simplest solution is most difficult to achieve. Thanks a lot you are a star.