GDS uses a consistent way of defining predicates on HTTP GET requests and distributed network queries. While each individual bucket is free to interpret predicates (F9) however it wishes, most implement the format described here. This formats primary aim is to be machine readable first and foremost. It also matches internal grid processing protocols used with GDS.
General Form
The general format of a predicate is
9=fNNN,OPERATER,OP-ARG(s)
NNN is the input field number to match against.
OPERATOR (Test Type) is a code taken from the table below
Code | Alternatives | Description | OP-ARGS | Examples | |
0 | =, eq | Exact Equals. For string values this includes being case sensitive so that abc does not equal ABC. The SQL equivalent is where fNNN=ARG | A single value. | 9=f150,0,3 9=f150,=,3 | Select where f150=3 |
1 | <, lt | < Less than. | 9=f150,1,3 9=f150,lt,3 | Select where f150<3 | |
2 | <=, le | <= | |||
3 | > | > | |||
4 | >= | >= | |||
5 | <>, != | <> (not equal) | |||
7 | like | like | |||
8 | like.ignorecase | like ignoring case | 9=f150,8,AB | Select where f150 is like %ab% or %AB% or %aB% or %Ab% | |
9 | =ignorecase | Equals ignoring case | f100,=ignorecase,cat | select where LOWER(f100) = LOWER(cat) | |
10 | NULL management. | ||||
11 | starting.ignorecase | Starting with, where the beginning of the value matches the supplied pattern | |||
16 | starting | Starting with, where the beginning of the value matches the supplied pattern |
OP-ARGs are encoded using eLink GDS standardised encoding formats ONLY.
Examples
9=f100,0,23
Restrict to rows where f100 is equal to 23
9=f101,8,ABC
Restrict to rows where f100 contains ABC. In SQL, the format would be
"where f101 like '%ABC%' ignore case"