I have a select query (using a prepared statement) which returns a Resultset. For example the query can be :
SELECT * FROM TABLE;
and I want the result of this query to insert in another table, the select query is stored at database and will be usually a join query, so i don't know exactly the columns of the table, how its possible for each row of the Resultset to make an insert row in the form:
INSERT INTO TABLE VALUES ('THE VALUES FROM THE SELECTED ROW IN THE RESULTSET');
you can do both in one state ment: