_lastUpdated & _createdAt
Filter by the modification date
Search by the last modification time of the resource meta.lastUpdated(note: ts column in database) or by the creation time meta.createdAt(note: cts column in the database)
FHIR format
Aidbox format
1
GET /fhir/Patient?_lastUpdated=2019-01-01
Copied!
1
GET /Patient?_lastUpdated=2019-01-01
Copied!
FHIR format
Aidbox format
1
GET /fhir/Patient?_createdAt=2019-01-01
Copied!
1
GET /Patient?_createdAt=2019-01-01
Copied!
Value can be a part of ISO date:
    only year - 2019
    year and month - 2019-03
    date - 2019-03-05
    hours - 2019-03-05T12
    mins - 2019-03-05T12:30
    secs - 2019-03-05T12:30:30
    micro-secs - 2019-03-05T12:30:30.333444
    with timezone - 2019-03-05T12:30:30Z or 2019-03-05T12:30:30+03
Do not forget url encode value of the expression in your code! Browser and Aidbox REST console will do some of encoding for you.
2019-03-05T12:30:30+03 =>2019-03-05T12%3A30%3A30%2B03
If you use = operator, Aidbox rounds the query date to the max and min value and searches in between this range:
1
ts <= max_date_bound('2019-01-01') AND ts >= min_date_bound('2019-01-01')
Copied!
You can use operators lt,le,gt,ge as the prefix of value to make Aidbox generate inequality queries:
1
_lastUpdated=lt2019-01 => ts < max_date_bound('2019-01')
2
_lastUpdated=ge2019-01 => ts >= min_date_bound('2019-01')
3
Copied!
Aidbox uses the PostgreSQL precision for lastUpdated/ts and createdAt/cts - it's usually micro-seconds
Last modified 6mo ago
Copy link