for(int j=0; j<artifactCount; j++)
{
String first = r2.getString("context");
for(int k=0; k<relevantCount; k++)
{
String second = r4.getString("context");
System.out.println(first + " " + second);
r4.next();
}
r2.next();
}
Hello all, I am trying to match each word of a coloumn with the other coloumn entries but first i'm trying to traverse the result using nested for loop. In 1st iteration the result comes correct, as there will be single word and a group of seperate words along side with it. Given below is the sample output of 1st iteration which is correct.
Technology Products
Technology Methodology
Technology Project management
Technology Risk
Technology Management
Technology Processes
Technology Capitalism
Technology Supply chain
Technology Skill
Technology Production and manufacturing
But in 2nd iteration it gives the following error as it doesn't traverse with the 2nd coming value with all the possible values.
java.sql.SQLException: After end of result set
at com.mysql.jdbc.ResultSet.checkRowPos(ResultSet.java:4353)
at com.mysql.jdbc.ResultSet.getStringInternal(ResultSet.java:2137)
at com.mysql.jdbc.ResultSet.getString(ResultSet.java:2132)
at com.mysql.jdbc.ResultSet.getString(ResultSet.java:2250)
at WebArtifactListener$2.run(WebArtifactListener.java:166)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Your help would be appreciated...thanx