You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried outputting column level lineage with the following query, but it did not output the desired result.
I specified a WEEK column, so shouldn't this query result in the test2 table?
fromsqlglot.lineageimportlineagesql='''withstep1 as ( select t1.* , d.up_date as week from test as t1 left outer join test2 as dim_cal on t1.dim_calendar_id = dim_cal.dim_calendar_id), step2 as ( select * , case when dayname(fiscal_date_shipping_basis) = 'Tue' then 'Mon' when dayname(fiscal_date_shipping_basis) = 'Wed' then 'Tue' when dayname(fiscal_date_shipping_basis) = 'Thu' then 'Wed' else 'Thu' end as dayname_of_closing_date from step1), test3 as ( select week , sales_order_id , dayname_of_closing_date , is_delete as is_deleted , fiscal_date_shipping_basis , dim_calendar_id from step2), final as ( select week , sales_order_id , is_deleted , dayname_of_shipping_date , fiscal_date_shipping_basis , dim_calendar_id from test3)select *from final'''column='WEEK'lin=lineage(column, sql, dialect='snowflake')
withopen(f'result.html', 'w') asf:
f.write(str(lin.to_html()))
result.html
The text was updated successfully, but these errors were encountered:
I tried outputting column level lineage with the following query, but it did not output the desired result.
I specified a
WEEK
column, so shouldn't this query result in thetest2
table?result.html
The text was updated successfully, but these errors were encountered: