> Do you have time series data that you want to join, but the timestamps don’t quite match? Or do you want to look up a value that changes over time using the times in another table?
The ASOF LEFT JOIN is the main join used to create training data, where the labels are in the left table, and features are in the tables on the RHS.
Note, we use DuckDB for its left asof join capabilities, but most vendors use Spark which is hideously slow for left asof joins.
https://code.kx.com/q/ref/asof/
https://code.kx.com/q/learn/brief-introduction/#time-joins
https://clickhouse.com/docs/en/sql-reference/statements/sele...
https://duckdb.org/docs/guides/sql_features/asof_join.html
> Do you have time series data that you want to join, but the timestamps don’t quite match? Or do you want to look up a value that changes over time using the times in another table?
DuckDB blog post on temporal joins:
https://duckdb.org/2023/09/15/asof-joins-fuzzy-temporal-look...
note: this idea is very useful for timestamps but can also be used for other types of values