Skip to content

Commit

Permalink
Update joins
Browse files Browse the repository at this point in the history
  • Loading branch information
chowbao committed Jan 23, 2024
1 parent 6739002 commit 479fea7
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions models/marts/trade_agg.sql
Original file line number Diff line number Diff line change
Expand Up @@ -101,19 +101,19 @@ with
from trade_yearly as join_table_yearly
left join
trade_weekly as join_table_weekly
on join_table_daily.day_agg = join_table_weekly.day_agg
and join_table_daily.asset_a = join_table_weekly.asset_a
and join_table_daily.asset_b = join_table_weekly.asset_b
on join_table_yearly.day_agg = join_table_weekly.day_agg
and join_table_yearly.asset_a = join_table_weekly.asset_a
and join_table_yearly.asset_b = join_table_weekly.asset_b
left join
trade_monthly as join_table_monthly
on join_table_daily.day_agg = join_table_monthly.day_agg
and join_table_daily.asset_a = join_table_monthly.asset_a
and join_table_daily.asset_b = join_table_monthly.asset_b
on join_table_yearly.day_agg = join_table_monthly.day_agg
and join_table_yearly.asset_a = join_table_monthly.asset_a
and join_table_yearly.asset_b = join_table_monthly.asset_b
left join
trade_daily as join_table_daily
on join_table_daily.day_agg = join_table_yearly.day_agg
and join_table_daily.asset_a = join_table_yearly.asset_a
and join_table_daily.asset_b = join_table_yearly.asset_b
on join_table_yearly.day_agg = join_table_daily.day_agg
and join_table_yearly.asset_a = join_table_daily.asset_a
and join_table_yearly.asset_b = join_table_daily.asset_b
)

select *
Expand Down

0 comments on commit 479fea7

Please sign in to comment.