Specifications
How to maintain extended attributes
294 InfoMaker
To pass the validation rule, the data must be all digits (must match the text
pattern
^[0-9]+$) and must be less than the amount in the Full_Price column.
Notice that to compare the numeric value in the column with the numeric value
in the
Full_Price column, the Real function was used to convert the text to a
number.
Example 3 In your company, a product price and a sales commission are
related in the following way:
• If the price is greater than or equal to $1000, the commission is between
10 percent and 20 percent
• If the price is less than $1000, the commission is between 4 percent and 9
percent
The
Sales table has two columns, Price and Commission. The validation rule for
the
Commission column is:
(Number(GetText( )) >= If(price >= 1000, .10, .04))
AND
(Number(GetText( )) <= If(price >= 1000, .20, .09))
A customized error message for the Commission column is:
"Price is " + if(price >= 1000,
"greater than or equal to","less than") +
" 1000. Commission must be between " +
If(price >= 1000,".10", ".04") + " and " +
If(price >= 1000, ".20.", ".09.")
How to maintain extended attributes
InfoMaker provides facilities you can use to create, modify, and delete display
formats, edit styles, and validation rules independently of their association with
columns. The following procedure summarizes how you do this.
❖ To maintain display formats, edit styles, and validation rules:
1 Open the Database painter.
2 Select View>Extended Attributes.
The Extended Attributes view displays listing all the entities in the
extended attribute system tables.