IF EXISTS (SELECT * FROM SYSOBJECTS WHERE NAME='#temp') DROP TABLE #tempGOSELECT ID,XM,ADDDW INTO #tempFROM CKZDGOSELECT * #tempDROP TABLE #temp