Working with business object attributes

Each business object normally includes several attributes, each of which provides a value that has been retrieved from a data source or provides a path for submitting updates to the data source. The top level of attributes are the primary fields accessed by a business object. Additional attributes can also be nested below subsets, but not all business objects use subsets.

To add an attribute to a business object

  1. Expand the business object where you want to add an attribute.
  2. Right-click on the top-level Attributes heading and choose Add Attribute.
  3. In the Properties - Add New Attribute dialog, type the following:

    Name - Name for this attribute. Only the characters a-z, A-Z and 0-9 are allowed.

    Type - Select from the list. This is the data type (date, integer, string, and others) that will be returned by the attribute.

    Size - Sets the maximum number of characters returned if you have chosen the "string" data type. This setting is not active for other types of data.

    Default value - Sets a default submit value for the attribute. When saving data to the database, this value will be entered into the database if no value is otherwise submitted.

  4. Select the applicable flags for this attribute. The flags are used to identify special attributes.
  5. Click OK.

Here are the available types.

Type Description
Boolean The value is either "true" or "false"
Decimal The value is a decimal number.
Double The value is a floating-point number
Integer The value is an integer
Date The value is a date
String The value is a text string, the length of which will not exceed the limit specified in the Size field.

Here are the available flags.

Flag Description
foreignkey Set this flag to mark the attribute as a foreign key. Attributes for which this flag is set will show a blue key icon in the Infor e-Commerce Development Studio
nullable Normally, attributes are not able to take a value of "null" (i.e., no value; not the same as zero). To allow null values for an attribute, regardless of its type, mark this check box. This changes the attribute from being a variable with an intrinsic Java data type to being an object (e.g., the variable "double" becomes the object "Double"), which can hold a value of null.
primarykey Set this flag to identify the key field for the set to which the attribute belongs (either the primary set or one of the subsets). This field must hold a unique value for each record of the set. Attributes for which this flag is set will show a yellow key icon in the Infor e-Commerce Development Studio
readonly Set this flag to prevent the business object from ever writing data to the fields addressed by the current attribute.

To edit an attribute

Double-click on the target attribute to open the properties window for that attribute. You can also right click on the attribute and select Properties.

In the Properties Dialog for the attribute, change the values as required.

Click OK.

To delete an attribute

Select an attribute then press Delete on the keyboard. You can also right click on the attribute and select Delete.

You shall be asked to confirm the action. Click Yes to delete the attribute.