Frequently asked question

How are date fields queried in an ArcIMS Image Service vs. an ArcMap Service?

Last Published: April 25, 2020


ArcIMS Image Service
To query date fields with an ArcIMS Image Service, the following syntax is used in the 'where' attribute of SPATIALQUERY:

{ts 'YYYY-MM-DD hh:mi:ss'}

This format cannot be used with ArcMap Services.

ArcMap Service
To query date fields of an ArcMap Service, different delimiters are used, depending on the data type that the map is referencing. Date fields in coverages, shapefiles and ArcSDE geodatabases comply with SQL standards, and are delimited as shown in the example below:

"DATE_FIELD" = date '1970-8-27'

Date fields in personal geodatabases are delimited as shown in this example:

[DATE_FIELD] = #1970/8/27#
Date field formats that are supported by native databases may also be used when working with ArcSDE geodatabases.

Article ID:000006129

  • Legacy Products

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options

Discover more on this topic