User-defined attributes capture all the detailed information about an object. The Attribute Setup Workbench enables you to create user-defined attributes with validation logic to support the needs of your organization. To do so, create value sets and associate the value sets with user-defined attributes. Attributes can have a static or dynamic list of valid values, or a range of values. For each user-defined attribute, you can optionally specify a value set with data type and validation rules to be applied when the user inputs data. Once created, value sets can be reused for different attributes. It is recommended that you create your value set before defining your attribute groups.
To create a value set:
On the Attribute Setup Workbench page, click the Value Sets tab.
Click Create.
On the Create Value Sets page that displays, enter the Value Set Name. This is the name by which the system and users keep track of the value set. You can only enter alphanumeric (a, b, c,..., 1, 2, 3,...) and the underscore ( _) characters for the value set name. You cannot use spaces or special characters. The length is limited to 15 characters. This is a mandatory field.
Note: Once specified, you cannot edit the value set name
Enter a Description for the value set.
Select a Data Type for your value set. The data type that you select determines the values that are available in the value set. An attribute's data type must match the data type specified for that attribute's value set. The different data types are:
Character
Number
Standard Date
Standard Date Time
Note: You cannot edit the data type once the value set has been created.
Enter value for Maximum Size if you wish to limit the user's input in the attribute text field. For example, in some cases you may wish to limit the number of characters in the attribute Date to 10 characters, or the number of characters in Name to 50. Keep the default value of 0 if you wish to omit this particular validation. This is a mandatory field.
Select a Validation Type from this list. This is a set of values against which the values entered by users are validated. You can choose from:
None - there is no explicit set of values against which the user's input is validated.
Independent - the explicit values against which the user's input is validated are defined here. To create explicit values, choose Poplist to display valid values as a drop-down list. Select List of Values radio to display valid values as a searchable list of values.
Translatable Independent - this validation type behaves the same as Independent, but enables the display of values in another language.
Table - the explicit values against which the user's input is validated comes from a database table. For Validation type Table, the value set can display as List of Values or Poplist.
Note: Use Poplist if the value set is likely to have < 5 values. It is recommended to use List of Values if the number of values fetched in a value set is greater than 5 - 10. Additionally, note that the LOV defaulting actions is supported only on attributes which have a value set of type List of Values.
Click Apply and Continue.
Depending on the Validation Type you selected, you can enter values for your value set.
If you selected Independent or Translatable Independent, then enter the following details
Enter a name for the Value. This is the name used to identify the value internally.
Optionally, enter a description for the value.
Ensure the Enabled check is selected.
Enter a Sequence for the value. This sequence number determines the order in which the value displays.
Optionally enter a Start Date and End Date.
Click Add Another to add another value to the value set.
If you selected Table as the validation type, then enter the following details:
Enter an Application Name. This is the name of the application in which the table is registered.
Enter a Table Name. This is the name of the database table or view in the schema.
In the Value Column section, enter the display name of the column. Enter the data Type of the value column, and the Size of the value column.
In the Meaning Column section, enter the description of the value that renders in the LOV window. Enter the Type to determine the data type of the meaning column. Enter the Size of the meaning column.
In the ID Column section, enter the internal value for the column. Enter the data Type of the ID column. Enter the Size of the ID column.
In the Where Clause section, enter an additional Where clause to further constrain a query. You can also use bind values in Where clauses in the following ways:
You can refer to other attributes in the same attribute group as the attribute that uses this value set by using the following syntax:
:$ATTRIBUTEGROUP$.<your attribute's internal name>
For example: (lookup_type='EGO_EF_Industry_TYPE' and instr(:$ATTRIBUTEGROUP$.Attr1 , tag) > 0 )
Note: In the example above, ensure you include a space between Attr1 and the comma for the SQL string to parse correctly.
You can refer to primary keys for the object to which the attribute group is associated by using the following syntax:
:$OBJECT$.<the object's primary key column name>
Click Apply.