select *, identity(int,1,1) as id into #t1 from table1
select *, identity(int,1,1) as id into #t2 from table2
select x1,x2,x3 from #t1 A left join #t2 B on A.id = B.id