To evaluate properties in an expression using an operator
- Select the command for which you want to create an expression.
- In the expression area, do one of the following:
- Enter a property name manually.
- Click Property. In the Property list, select a property.
- 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.
-
You can use the following types of operators:
-
Math Operators
For example, this expression could be used to label repair locations with 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 parcels whose assessed value is $100,000 or more, use this expression:
PARCEL_VALUE >= 100000
-
Logical Operators
For example, to find only parcels that have a value for the PARCEL_OWNER property, use this expression:
NOT ADDRESS NULL
To find all parcels except those on Dewberry Drive or Lavendar Way, use one of these expressions:
NOT ( STNAME = 'DEWBERRY DR' ) AND NOT ( STNAME = 'LAVENDER WAY' )
NOT Property IN ( 'DEWBERRY DR','LAVENDER WAY')
-
Math Operators
- Select or type the value to evaluate.
- 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 parcels whose last purchase date is after 1990 and before 2005, the expression must look like this one:
PURCHASE_DATE > 1990 AND PURCHASE_DATE < 2005
- Click OK to apply the expression.
To evaluate properties in an expression using a function or option
- Select the command for which you want to create an expression.
- 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 Functions
For example, to find the square root of the value representing parcel area, use this expression:
Sqrt(PARCEL_AREA)
-
Numeric Functions
Numeric functions are available from the Math Functions menu. For example, to round the assessed value of parcels down to the nearest lower whole dollar, use this expression:
Floor(PARCEL_VALUE)
-
Text Functions
For example, to convert pipe names to all uppercase letters, use this expression:
Upper(PIPE_NAME)
-
Date Functions
For example, to add one month to the start date for a project, use this expression:
AddMonths(START_DATE, 1)
You can use the following types of options:
-
Geometric Options
Geometric options may include Area, Length2D, M, X, Y, and Z (depending on the feature source). For example, to find the perimeter value for parcels, use this expression (when Parcels is the current feature or layer):
Length2D(geometry property)
Note:The Geometry property may have a different name in your data store. It is always listed under Geometry Properties in the Property list. Insert the property from the list. Do not change it manually or substitute a value for this property.
-
Conversion Options
For example, to create label text that displays “Unoccupied” if the property Occupied is null, use this expression:
NullValue(OCCUPIED, 'Unoccupied')
-
Math Functions
- In your expression, do one of the following:
- Enter a property name manually.
- Click Property. In the Property list, select a property.
- Select or type the value to evaluate.
- To create a complex property evaluation, insert an AND or OR operator, and then insert another operator, property, and value combination.
- Click OK to apply the expression.