2:
insert into menuview '','','',''...
select '','','',''...
union all select '','','',''...
union all select '','','',''...
insert into menuview '','','',''...
select '','','',''...
union all select '','','',''...
union all select '','','',''...
如果因为处理需要而要求回滚事务,则直接用rollback tran就行了.
inner join
是会把b表的数据全部查询出来,即使A表没有a.x=b.x的数据
而第一句只是把符合条件的数据查询出来,
如:a 100笔数据,b 100笔数据
a.x=b.x 的数据有20笔,则第一句会查询20*20次
而第二句查询20*100次
3、在sql server没有区别,但是select a.x,y,z from a inner join b on a.x=b.x是符合SQL-92标准的,移植性更好,说第一句比第二句好没有道理