两个不相关联的表,从一个表中查询出来一个字段作为新纪录插入到另外一个表中
insert into d_role2privilege
select seq_master.nextval,
A.Role_Code,
B.Privilege_Id,
1,
1,
'SYSTEM',
sysdate,
null,
null
from d_role A,
(select privilege_id
from d_privilege
where privilege_id like 'S041.1%') B
一个role_code对应三个privilege_id