datasets#
One row per dataset. This is the usual entry point for a session, because telemetry queries have to name the dataset(s) they read and this table needs no scoping to read.
Metadata table, so no dataset_rid predicate is required.
For how datasets hold ingested data, see Datasets in the data model.
Columns#
Column |
Type |
Nullable |
Notes |
|---|---|---|---|
|
|
No |
Resource ID. This is the value telemetry queries filter on. |
|
|
No |
Dataset name. |
|
|
Yes |
Free-text description. |
|
|
No |
Labels applied to the dataset. |
|
|
No |
Key-value properties applied to the dataset. Read a value with |
|
|
Yes |
Earliest data time across the dataset. Null when the dataset holds no data, or has no stored bounds. |
|
|
Yes |
Latest data time across the dataset. Null when the dataset holds no data, or has no stored bounds. |
Some datasets, such as the one behind a newly created asset, have no stored bounds, so their bounds_start and bounds_end are null even when they hold data.
Examples#
Find a dataset to query:
SELECT dataset_rid, name FROM datasets LIMIT 20
Search by name. Matching is case-sensitive, so normalize when you’re unsure of the casing:
SELECT dataset_rid, name, bounds_start, bounds_end
FROM datasets
WHERE UPPER(name) LIKE '%<NAME TEXT>%'
ORDER BY name
Only datasets with stored bounds, latest first:
SELECT dataset_rid, name, bounds_start, bounds_end
FROM datasets
WHERE bounds_start IS NOT NULL
ORDER BY bounds_start DESC
LIMIT 20
Filter on a property:
SELECT dataset_rid, name
FROM datasets
WHERE properties['<key>']['value'] = '<value>'
ORDER BY name
Note
bounds_start and bounds_end span the whole dataset. Individual channels may cover narrower ranges; query channels to see which channels exist.
Next steps#
channels: what’s inside a dataset.
points_double: read the samples.