When to use join vs union

If you want to append two tables one below another with exact same columns, union is the command to be used. Join should be used if the tables observations are to be merged based upon observations of the common column.

For example, in formulating sales data, if I have sales information for the year of 2019 and 2020 and I want to collate it one below another union is the command. Whereas if I need Sales_2019 as 1 column and sales_2020 as another column I should go for join.