Adding table domains

You add a table domain when you want to add a domain that draws its values directly from a column in the database. This process creates a dynamic value list because the values it draws from the database might change.

Procedure

  1. Open the Domains application.
  2. In the Domains table window, click Add New Domain and select Add New TABLE Domain.
  3. In the Domain field, specify a name for the domain.
  4. In the Description field, type a short description for the domain.
  5. Click New Row and fill the following fields.
    Field Description
    Object Specify the name of the object. The object you want is the object containing the attribute from which you want to create a domain.

    For example, to obtain values from the ASSET object, specify ASSET.

    List Where Clause Type the part of the clause that specifies the values that you want to select based on the validation WHERE clause.

    For example, to select asset records that begin with the numbers 114, type: assetnum like '114%'

    Attention: The system does not validate your entry for syntax or any other errors. Be sure that you have typed a correct WHERE clause. If you make errors, errors do not become apparent until you configure the database.
    Validation Where Clause If the value to be validated by this domain is considered valid, type the part of the clause that when queried against the object in the Object field should return at least one record.

    Usually, the clause involves a bind variable for the field that uses this domain for validation. The bind variable is represented by a colon (:) followed by the field name.

    For example, if you want a field named Z (attribute Z) to contain values from the assetnum field in the Assets application, type: assetnum = :z

  6. Optional: Specify a group value and a key value to select an error message to display when domain validation fails. You define values for error messages in the Database Configuration application.
    1. In the Error Message Group field, specify the group value of the error message.
    2. In the Error Message Key field, specify the key value of the error message.
  7. Optional: Apply a domain value to a specific organization or site by specifying values in the Organization and Site fields. Domains are applied at the system level by default.

    You might want to leave the Organization and/or Site fields empty for all values so that users in all organizations and sites can access them. Or you could specify organization and/or site for all values so that only users in the specified organizations and/or sites can access them.

  8. Optional: Click New Row again to add more rows.
  9. Click OK.

What to do next

After you add a domain, you might still have several tasks to perform, depending on the domain and how you want to display it.

In the Classifications application, you associate a domain with an attribute in the Attributes table window, and no further configuration is needed.

If you use a domain in any other context, adding a domain requires additional tasks:
  • Associate the new domain with an attribute in the Database Configuration application.
  • Configure the database in the Database Configuration application.
  • Use the Application Designer application to modify the user interface as needed. For example, if you add an ALN domain for a field, you must add the select value button. New crossover domains might require new fields in the destination application.


Feedback