inserting data into new table from union of two tables
问题 I have a following query that unions two tables Table1 and Table 2 ResultSet res = st.executeQuery(" select user_id, movie_Id, movie_name, user_name, rating, genre from Table1 union all select t1.user_id, t2.movie_Id, t2.movie_name, t2.user_name, t2.rating, t2.genre from Table2 t2 join Table1 t1 on t2.user_name = t1.user_name;"); output-- 1 12 pianist vishal 7 action 2 4 titanic rajesh 7 action 3 5 snakes on a plane anuj 2 drama 4 9 oh my god arun 5 drama 5 9 jumanji vishal 8 fantasy 6 68 the