如果表b为空
insert into b
select rownum id,t.* from
(select * from b,d from a
order by b,d) t;如果b原先有数据,序号id目前为n
insert into b
select rownum+n id,t.* from
(select * from b,d from a
order by b,d) t;
insert into b
select rownum id,t.* from
(select * from b,d from a
order by b,d) t;如果b原先有数据,序号id目前为n
insert into b
select rownum+n id,t.* from
(select * from b,d from a
order by b,d) t;
楼主是不是应该写成"B表的id列是序号(可以是序列)"insert into b
select rownum,t.* from (select b,d from a order by b,d) t;