Product help with community knowledge

### Page statistics

1845 views1 edit(s)19342 characters(s) Page last modified 09:56, 10 Aug 2011 by sdavis131

# Evaluating Properties

You can use expressions to evaluate properties. Here are some examples:

• Find all features in a feature class that have a property equal to, greater than, or less than a particular value. For example, find all buildings with a creation date value greater than January 1, 2000.
• Select all the features in a feature class with a property that matches a pattern you specify. For example, select all roads whose names begin with “Mt.”
• Create a table entry for a feature class with the value of a particular property, rounded in a particular way. For example, display building area, rounded up to the nearest whole number.

You can enter property names directly into an expression, or you can select them from the Property list.

If you enter a property name that is not in the Property list, the Validate operation may issue a warning. However, if that property exists in your data store, the expression may still be valid when it is run.

You can also view and insert the valid values for any listed property.

The syntax for an expression that evaluates a property is slightly different, depending on whether you use an operator, a function, or an option. For an operator, the basic syntax is PROPERTY Operator Value. For functions and options, the basic syntax is Function (PROPERTY).

To evaluate properties in an expression using an operator

1. Select the command for which you want to create an expression.
2. In the expression area, do one of the following:
• Enter a property name manually.
• Click Property. In the Property list, select a property.
3. Enter an operator using one of these methods:
• Enter an operator manually.
• Click an operator button.

Use the Operator buttons.

• Select an operator from a menu.
4. You can use the following types of operators:

• Math Operators

For example, this expression could be used to determine the total amount spent on parts and labor for a pipe repair project:

PIPE_PARTS_COST + PIPE_LABOR_COST

• Comparison Operators

For example, to find buildings whose assessed value is \$100,000 or more, use this expression:

VALUE >= 100000

• Logical Operators

For example, to find only buildings that have a value for the TERMINATION_DATE property, use this expression:

NOT TERMINATION_DATE NULL

5. Select or type the value to evaluate.
6. To create a complex property evaluation, insert an AND or OR operator, and then insert another property, operator, and value combination.

Precede every operator with a property. For example, to find buildings whose creation date is after 1990 and before 2005, the expression must look like this one:

CREATION_DATE > 1990 AND CREATION_DATE < 2005

7. Click OK to apply the expression.

To evaluate properties in an expression using a function or option

1. Select the command for which you want to create an expression.
2. In the expression area, do one of the following:
• Type a function or option for this property.
• Select a function or option from a menu.

You can use the following types of functions:

• Math Operators

Math operators perform arithmetic functions. For example, to round the bank width value for water features up to the next whole number and then find water features whose rounded bank width is more than 4 feet, use this expression:

Ceil(BANK_WIDTH) > 4

• Numeric Functions

Numeric functions operate on properties whose valuues are numbers. For example, to round the height of buildings down to the nearest lower whole number and then find buildings whose rounded hieght is less than 8 feet, use this expression:

Floor(ROOF_HEIGHT) < 8

• Text Functions

Text functions operate on textual values. For example, to convert pipe names to all uppercase letters, use this expression:

Upper(NAME)

• Date Functions

Date functions operate on date values. For example, to add one month to the start date for a project, use this expression:

You can use the following types of options:

• Geometric Options

Geometric options may include Area, Length2D, M, X, Y, and Z (depending on the data source). For example, to find buildings whose area is greater than 10,000 square feet, select the Buildings feature class and use this expression:

Area2D(GEOMETRY) > 10000

• Conversion Options

Conversion options change values. For example, to display “None” if the property USE_TYPE is null, use this expression:

NullValue(USE_TYPE, 'None')

3. In your expression, after the function, enter a property name manually or choose one from the Property list.
4. Select or type the value to evaluate.
5. To create a complex property evaluation, insert an AND or OR operator, and then insert another operator, property, and value combination.
6. Click OK to apply the expression.