inner join calendar_t cal on cal.week_id = wh.week_period inner join fiscal_year_t fy on fy.fiscal_year_id = wh.fiscal_year_id and fy.fiscal_year = cal.fiscal_year ...
Read this SQL tutorial to learn when to use SELECT, JOIN, subselects and UNION to access multiple tables with a single statement. It’s sometimes difficult to know which SQL syntax to use when ...