Използвайте insert ... select заявка и поставете известните стойности в select :
insert into table1
select 'A string', 5, idTable2
from table2
where ...
Използвайте insert ... select заявка и поставете известните стойности в select :
insert into table1
select 'A string', 5, idTable2
from table2
where ...