Hello gurus,
I am trying to get insert query name and insert xml doc in tokens from
the properties file and run the jdbc queries in sequence. I am trying
to do using Tokenizer class, Can you pls suggest if this is the right
way of doing it or not? I would like to do it using List so that I
have better control over elements of it. any suggestion? Thanks alot !
String insertSQL = prop.getProperty("insert.sql");
String insertDOC = prop.getProperty("insert.doc");
StringTokenizer st1 = new StringTokenizer(insertSQL, " ");
StringTokenizer st2 = new StringTokenizer(insertDOC, " ");
String iQuery=null;
String iDoc=null;
while (st1.hasMoreTokens() && st2.hasMoreTokens()) {
iQuery = st1.nextToken();
iDoc = st2.nextToken();
insertQuery(iQuery, iDoc, ,conn);
}
hussainak@gmail.com - 15 Mar 2006 22:15 GMT
thts a bad practice.....
juss load the results in an array, close the connection...then run a
for loop on the array to retrieve the results or perform any operations