(select resak.resak001,resak.resak002,resak.resak005,resak.resak006, resal.resal001 AS EXPR3, resak.resak015 AS EXPR4, resal.resal002
into tempTable FROM resak INNER JOIN
resal ON resak.resak015 = resal.resal001
where resak.resak005='silvia_tsai.nettrade.com.tw' and resak.resak001!='9999' and resak.resak001 !='1947')
select MV001,MV002,MV021,MV022 into tempTableFromCMSMV from [172.16.200.81].Leader.dbo.CMSMV
select * from tempTable
select * from tempTableFromCMSMV
select tempTable.resak001,tempTable.resak002,tempTableFromCMSMV.MV021,tempTableFromCMSMV.MV022
FROM tempTable INNER JOIN
tempTableFromCMSMV ON tempTable.resak001 = tempTableFromCMSMV.MV001