Customizing Flexfields

The Maintain Discrepancy Database window includes two editable fields that have the default labels Flexfield1 and Flexfield2. You can use them to store information you need. You can change their labels, make the fields mandatory if you want, and create a dynamic or static list of values for each field:

  • Static List of Values. By default, the fields get their list of values from a database view that references the local reference codelists DISC_FLEX1_VALUES and DISC_FLEX2_VALUES. You can populate these reference codelists to create lists of values for the two fields.
  • Dynamic List of Values. Alternatively, you can reprogram the view to reference another Oracle Clinical table or even an Oracle table outside Oracle Clinical, such as an adverse event code maintained in a different Oracle system. In each field you can display any column value or concatenation of column values.

    The views, DISCREP_FLEX1 and DISCREP_FLEX2, respectively, are created during installation as follows:

    create or replace view discrep_flex1 as
    select   ref_codelist_value_short_val VALUE,
                long_value DESCRIPTION
    from reference_codelist_values
    where ref_codelist_name = 'DISC_FLEX1_VALUES'
    and active_flag='Y';

For more information, see:

DISC_FLEX1 and DISC_FLEX2

Use these local reference codelists to customize the label for Flexfield1 or Flexfield2, to enable the field, to make the field mandatory or not, and to specify whether or not there is a list of values for the field.

Table 3-7 DISC_FLEX1 and DISC_FLEX2 Settings

Short Value Long Values Description

ENABLED

Y or N

Set the long value to Y to allow users to enter values in the field. Set to N to prevent users from entering values in the field.

REQUIRED

Y or N

Set the long value to Y to require users to enter text in this field. Set to N to make the field optional.

PROMPT

text

Enter freeform text as the long value. This text becomes the field label in the Discrepancy Database window.

LOV_VALIDATE

Y or N

Set the long value to Y to require the system checks the entry against an list of values. An invalid entry triggers the system to display the associated list of values.

DISC_FLEX1_VALUES and DISC_FLEX2_VALUES

If you set LOV_VALIDATE to Y in DISC_FLEX1, you can create a static list of values by entering each allowed value in a row in this codelist. When a user displays the list of values in the Discrepancy Database window, the system displays the short value and description for each row you enter here. (Alternatively, create a dynamic list of values; see Customizing Flexfields.)

The long value is used as the description in the Flexfield1 (or 2) field's list of values. The short value is stored in the FLEX_FIELD1 (or 2) column in the DISCREPANCY_ENTRIES table in the database. The default value has no effect.

Table 3-8 DISC_FLEX1_VALUES and DISC_FLEX2_VALUES Codelists

Field Name Description

Seq

Determines the order of the values in the list of values for the flexfield.

Short Value

Is the stored value when the user selects the row from the list of values.

Long Value

Can duplicate the short value; is not displayed in the list of values.

Active box

Select the Active check box to have the entry appear in the list of values.

Default

Identifies which value is the default value.

Description

Provides additional information about the value; the information displays in the list of values.

Example

To customize Flexfield1 to ask the creator of a manual discrepancy record if the record is finished, and test the response entry against a list of three values, you would set the flexfield1 codelist values to the values in the following two tables, with the three values defined in the second. (Values that differ from the default values are in italics.)

Table 3-9 DISC_FLEX1 Settings to Make a Finished? Prompt

Seq Short Value Long Value Active Default Description

1

ENABLED

Y

Selected

-

Flexfield1 Displayed

2

REQUIRED

N

Selected

-

Flexfield1 Required

3

PROMPT

Finished?

Selected

-

Flexfield1 Prompt

4

LOV_VALIDATE

Y

Selected

-

Flexfield1 list of values Validate

Table 3-10 DISC_FLEX1_VALUES Settings for a Finished? List of Values

Seq Short Value Long Value Active Default Description

1

Y

Yes

Selected

-

-

2

N

No

Selected

-

-

3

U

Undetermined

Selected

Selected

-