Query Union is giving error

Hi

Here is my query

select pf.*
into #temp_2017
from FactTable pf inner join TimeTable T
ON pf.timeID = T.timeID AND t.timeYear = 2017

select pf.*
into #temp_2018
from FactTable pf inner join TimeTable T
ON pf.timeID = T.timeID AND t.timeYear = 2018

declare @period1 varchar(10),@period2 varchar(10)
set @period1 = '2017 06'
set @period2 = '2018 05'

SELECT pf.*
INTO NewTable
FROM #temp_2017 pf inner join TimeTable T ON pf.timeID = T.timeID AND T.timeMonth >= @period1
UNION
SELECT * FROM #temp_2018 pf inner join TimeTable T ON pf.timeID = T.timeID AND T.timeMonth >= @period2

when I execute the

Select pf.*....
Union
Select * ... (not pf.*)

The two select statements are (probably) not returning the same columns, so the union is unhappy

thanks, got it resolved. happy weekend