Hive で LATERAL JOIN を実行したいと考えています。これをサポートする方法はありますか?本質的に、LHS の行の値を RHS の任意の SQL のパラメーターとして使用したいと考えています。
以下は Postgres の例です: (粗雑な例を許してください):
create table lhs (
subject_id integer,
date_time BIGINT );
create table events (
subject_id integer,
date_time BIGINT,
event_val integer );
SELECT * from lhs LEFT JOIN LATERAL ( select SUM(event_val) as val_sum, count(event_val) as ecnt from events WHERE date_time < lhs.date_time and subject_id = lhs.subject_id ) rhs1 ON true;