Common Query Language (CQL)¶
This document describes the basic syntax of the common query language. CQL is the query language defined the Catalogue Service specification (CSW). CQL support in EOxServer is realized using the external pycql package.
This document is based upon the (E)CQL documentation of GeoServer with adapations wherever needed.
Syntax Specification¶
This chapter shows the syntax to define CQL queries.
Condition¶
Syntax |
Description |
---|---|
A single predicate expression |
|
Logical combination of two conditions |
|
|
Logical inversion of a condition. |
|
Grouping of conditions regarding evaluation order |
Predicate¶
Syntax |
Description |
---|---|
Expression |
Comparison of two expression |
Expression [ |
Value range Comparison |
Expression [ |
Check whether an expression matches a pattern. The
|
Expression [ |
Tests the inclusion of a value in a set of values. |
Expression |
Tests whether the evaluated expression is |
Expression |
|
Expression |
|
Expression |
|
Expression |
|
Expression |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Expression¶
Syntax |
Description |
---|---|
Name of an objects attribute |
|
A literal value |
|
Expression |
Arithmetic operations of two expressions |
|
Grouping of expression regarding evaluation order |
Literal¶
Syntax |
Description |
---|---|
Number |
A literal number (either floating point or integer |
Boolean |
A literal booelan value: either TRUE or FALSE |
Timestamp |
A timestamp literal. Must be in ISO 8601 compliant datetime format. |
Duration |
A timestamp literal. Must be in ISO 8601 compliant duration format. |
Geometry |
A Geometry in WKT format. EPSG:4326 is assumed |
Period¶
Syntax |
Description |
---|---|
Period definition using the start and end timestamp. |
|
Period definition using the start timestamp and a duration afterwards. |
|
Period definition using the end timestamp and a duration before. |
Attribute¶
Depending on the current query context, the following attributes are available to use in the queries.
Attribute name |
Field type |
Availability |
---|---|---|
identifier |
String |
All |
beginTime |
Timestamp |
All |
endTime |
Timestamp |
All |
footprint |
String |
All |
inserted |
Timestamp |
All |
updated |
Timestamp |
All |
productType |
String |
Collection |
doi |
String |
Collection |
platform |
String |
Collection |
platformSerialIdentifier |
String |
Collection |
instrument |
String |
Collection |
sensorType |
String |
Collection |
compositeType |
String |
Collection |
processingLevel |
String |
Collection |
orbitType |
String |
Collection |
spectralRange |
String |
Collection |
wavelength |
Number |
Collection |
parentIdentifier |
String |
Product |
productionStatus |
String |
Product |
acquisitionType |
String |
Product |
orbitNumber |
Number |
Product |
orbitDirection |
Number |
Product |
track |
Number |
Product |
frame |
Number |
Product |
swathIdentifier |
String |
Product |
productVersion |
String |
Product |
productQualityStatus |
String |
Product |
productQualityDegradationTag |
String |
Product |
processorName |
String |
Product |
processingCenter |
String |
Product |
creationDate |
Timestamp |
Product |
modificationDate |
Timestamp |
Product |
processingDate |
Timestamp |
Product |
sensorMode |
String |
Product |
archivingCenter |
String |
Product |
processingMode |
String |
Product |
availabilityTime |
Timestamp |
Product |
acquisitionStation |
String |
Product |
acquisitionSubType |
String |
Product |
startTimeFromAscendingNode |
Number |
Product |
completionTimeFromAscendingNode |
Number |
Product |
illuminationAzimuthAngle |
Number |
Product |
illuminationZenithAngle |
Number |
Product |
illuminationElevationAngle |
Number |
Product |
polarisationMode |
String |
Product |
polarizationChannels |
String |
Product |
antennaLookDirection |
String |
Product |
minimumIncidenceAngle |
Number |
Product |
maximuIncidenceAngle |
Number |
Product |
dopplerFrequency |
Number |
Product |
incidenceAngleVariation |
Number |
Product |
cloudCover |
Number |
Product |
snowCover |
Number |
Product |
lowestLocation |
Number |
Product |
highestLocation |
Number |
Product |