Lets say you want to execute a query like this :
ResultSet rs = statement.executeQuery("select * from people");
You would iterate of the results with something like this:
while(result.next()) {
// ... get column values from this record
}
Then you just reuse the variable rs
to execute another query like:
rs = statement2.executeQuery("select * from cars");
Here is a tutorial on working with ResultSet