Query Criteria Operators for Date Fields

When you define a query and select date fields as filters, the criteria operator labels use terminology that is more easily associated with date information than the labels that appear for other types of fields.

The table below explains the date filter operators. To learn about the criteria operators for other types of fields, refer to Query Criteria Operators.

Operator

Description

Is

When you select this condition, the program returns records that include the exact value you define. For example, if you select Date added "Is" 01/01/2014, the results only include records with the exact date added value of 01/01/2014.

Is not

When you select this condition, the program returns records that do not include the exact value you define.

For some fields, the Only return records that do not have a value equal to the selected value checkbox appears. To not return records associated with the value selected for the field, regardless of whether the record is associated with additional values for the field, select this checkbox. If you do not select the checkbox, the results do not include records associated with the value you select, but do include records for additional values for the field.

Note: The Include blanks checkbox appears for the date criteria operators of "Is not," "Not one of," "Before," "On or before," "Not between," "Not like," and "Does not contain." To include records with no entry for the selected field, select this checkbox. If the checkbox is not selected, records with no entry for the field do not appear in the results. From Administration, you can use the Enable/Disable default blank query criteria configuration task select whether to select Include blanks by default.

One of

When you select this condition, the program returns records that include one of the values you define. For example, if you select Date added is "One of" 01/01/2014 or 02/02/2014, the results include records with a date added value of either 01/01/2014 or 02/02/2014.

For some fields, the Only return records that match all selected values checkbox appears. To return only records that match all the values defined, select this checkbox. If you do not select the checkbox, the program returns records associated with any combination of values you define. The record does not have to be associated with all the values, but must be associated with at least one.

Not one of

When you select this condition, the program returns records that do not include any of the values you define. For example, if you select Date added is "Not one of" 01/01/2014 or 02/02/2014, the results include records with a date added value other than 01/01/2014 or 02/02/2014.

Before

When you select this condition, the program returns records that include a date value before the one you define. For example, if you select Date added is "Before" 01/01/2014, the results include records with a date added before 01/01/2014. The results do not include records with a date added value of 01/01/2014 or later.

On or before

When you select this condition, the program returns records that include a date value on or before the one you define. For example, if you select Date added is "On or before" 01/01/2014, the results include records with a date added value of 01/01/2014 or earlier. The results also include records with the value you select, in this case 01/01/2014.

After

When you select this condition, the program returns records that include a date value after the one you define. For example, if you select Date added is "After" 01/01/2014, the results include records with a date added value after 01/01/2014. The results do not include records with a date added value of 01/01/2014 or earlier.

On or after

When you select this condition, the program returns records that include a date value on or after the one you define. For example, if you select Date added is "On or after" 01/01/2014, the results include records with a date added value of 01/01/2014 or later. The results also include records with the value you select, in this case 01/01/2014.

Between

When you select this condition, the program returns records that include a date value within the range you define. This operator is inclusive. For example, if you select Date added is "Between" 01/01/2014 and 01/01/2015, the results include records with a date added value between 01/01/2014 and 01/01/2015, as well as records with a date added value of 01/01/2014 and 01/01/2015.

Not between

When you select this condition, the program returns records that do not include a date value within the range you define. This operator is exclusive. For example, if you select Date added is "Not between" 01/01/2014 and 01/01/2015, the results include records with a date added value before 01/01/2014 and after 01/01/2015. The results do not include records with date added value equal to 01/01/2014 and 01/01/2015.

Blank

When you select this condition, the program returns records that do not include an entry in the field. For example, if you select Birth date is "Blank," the results include records without a birth date value.

Not blank

When you select this condition, the program returns records that include an entry in the field. For example, if you select Birth date is "Not blank," the results include all records with a birth date value.

 

 

You are here: Overview > Need Help with Analysis? > Information Library > Ad-Hoc Queries > Create Ad-Hoc Queries > Query Criteria Operators > Query Criteria Operators for Date Fields