--判断虚拟表是否存在IF Object_ID(N'tempdb..#tmpOrderm') is not Null drop table #tmpOrderm--判断内容是否存在if not exists (select * from Common_ImportData_Log where RID=@log_rid)