insert into ti_examinee_group_link(GROUP_LINK_ID, EXAMINEE_ID, group_id)
select seq_ti_examinee_group_link.nextval, t.examinee_id,1
from ti_examinee_info t
left join ti_examinee_group_link b on t.examinee_id =b.examinee_id
left join ti_exam_group c on b.group_id = c.group_id
left join ti_exam_batch d on c.batch_id = d.batch_id
where t.batch_id=2 AND b.group_id IS null and t.signposition_code='20202'
注:直接在插入值的后面用select来查出into后面对应的数据。