create table t1(id int, feild int);insert into t1 values(1 , 1);insert into t1 values(1 , 2);insert into t1 values(1 , 3);insert into t1 values(1 , 4);insert into t1 values(2 , 1);insert into t1 values(2 , 2);create table t2(id int, feild int);insert…