![]() |
CAIRS Operators |
You can set parameters or specify a search in CAIRS using the OR and AND logical operators.
Search terms combined with the Boolean AND will return records that contain all of the search terms. Search terms combined with the Boolean OR will return records that contain any of the search terms. When more than one logical operator is used in a statement, AND is processed first, but the order of execution can be changed by using parentheses. NOT can be used to negate either logical operator and will return records that do not contain the search terms.
The logical operators are used within edit boxes. Edit boxes are labeled with the CAIRS search field name for which the parameters will be set. The logical operators can be used with narrative, coded, numeric and date/time fields. The operators are not case sensitive and, therefore, can be entered in either lower, upper, or mixed case. Examples are shown in the table below.
You can set parameters or specify a search in CAIRS using wildcard operators: % and _ .
The % operator specifies zero or more of any alphanumeric character. For example, sa% locates reports that contain any one of the following: "safety," "saline," "sat," "satisfy," "salient," etc.
The _ (underscore) operator specifies exactly one alphanumeric character. For example, sa_ locates reports that contain any one of the following: "sag," "sap," "sat," "sax," etc.
The wildcard operators are used within edit boxes. Edit boxes are labeled with the CAIRS search field name for which the parameters will be set. The wildcard operator can be used with narrative, coded, and date/time fields. Examples are shown in the table below.
You can set parameters or specify a search in CAIRS using the BETWEEN range operator. This operator is used to specify a numerical range or a range or codes.
The syntax for the BETWEEN operator is BETWEEN X AND Y. Search terms combined with the BETWEEN operator will return records that contain all of the search terms through the range X and the Y, including X and Y. NOT can be used to negate the range operator and will return records that do not contain the search terms.
The range operators are used within edit boxes. Edit boxes are labeled with the CAIRS search field name for which the parameters will be set. The range operator can be used with coded, and date/time fields. The operator is not case sensitive and, therefore, can be entered in either lower, upper, or mixed case. Examples are shown in the table below.
You can set parameters or specify a search in CAIRS using the <, >, >=, <=, =, and <>, relational operators.
The < operator will return records with values less than the search term, the > operator will return records with values greater than the search term, the >= will return records with values greater than or equal to the search term, the <= will return records with values less than or equal to the search term, the = will return records with values equal to the search term, and the <> will return records with values not equal to the search term.
The relational operators are used within edit boxes. Edit boxes are labeled with the CAIRS search field name for which the parameters will be set. The relational operators can be used with narrative, coded, numeric and date/time fields; however, if relational operators are used with narrative, coded, or date/time fields, the field must be enclosed in single quotes. Examples are shown in the table below.
| CAIRS search field(s) | Example Entry | Explanation |
| Org Code | 0501001 or 0502209 | This entry will retrieve records where either organization 0501001 or 0502209 (Albuquerque Office or the Central Training Academy) are the reporting organization. |
| All Narrative | lockout and tagout | This entry will retrieve records where both "lockout" and "tagout" are found in the narrative fields. |
| Body Part Code | 03% | This entry will retrieve records where any face locations is listed as the body part injured. |
| Body Part Code | 03% and not 0311 | This entry will retrieve records where any face location, except tooth/teeth, is listed as the body part injured. |
| Case Number | between 95001 and 95025 | This entry will retrieve records where the case number is 95001 through 95025 (including 95001 and 95025). |
| Case Number | <= '95025' and >= '95001' | This entry will retrieve records where the case number is less than or equal to 95025 and greater than or equal to 95001. |
| Total Dollar Loss | >= 10000 | This entry will retrieve records where the total dollar loss is greater than or equal to $10,000. |
CAIRS Help Table of Contents |
CAIRS
Help Index |