run_assets#

One row per run-and-asset pair, recording which assets a run covers. A run spanning several assets has one row here for each.

Metadata table, so no dataset_rid predicate is required. The table has no dataset_rid column at all.

For how runs relate to the assets they cover, see Runs in the data model.

Columns#

Column

Type

Nullable

Notes

run_rid

VARCHAR

No

The run. Joins to runs.run_rid.

asset_rid

VARCHAR

No

The asset. Joins to assets.asset_rid.

This is a join table and carries nothing else. Read titles, times, and properties from runs and assets.

Examples#

Which assets a run covered:

SELECT a.title
FROM run_assets AS ra
JOIN assets AS a ON ra.asset_rid = a.asset_rid
WHERE ra.run_rid = '<run-rid>'
ORDER BY a.title

Which runs touched an asset, most recent first:

SELECT r.title, r.start_time, r.end_time
FROM run_assets AS ra
JOIN runs AS r ON ra.run_rid = r.run_rid
WHERE ra.asset_rid = '<asset-rid>'
ORDER BY r.start_time DESC
LIMIT 20

Assets ordered by how many runs cover them:

SELECT a.title, COUNT(*) AS runs
FROM run_assets AS ra
JOIN assets AS a ON ra.asset_rid = a.asset_rid
GROUP BY a.title
ORDER BY runs DESC

Note

run_assets connects runs to assets, not either of them to telemetry. Neither side carries a dataset_rid, so it cannot bridge to points_double or logs. Use a run’s start_time and end_time as a ts filter once you know which dataset to read.

Next steps#

  • runs: run titles, times, and properties.

  • assets: asset titles and properties.