|
Hi, I am using AS/400 Toolbox for Java to connect the DB2 database on AS/400 (type 4 JDBC driver). I run the Java program on NT client machine using VAJ. I have two questions here. 1) What will be the proper size to have the data in a result set? One time I have 220,000 rows in one result set. Then process the data and update the results back to the database. This was done on the same table. I tested that it will be faster to have all data in one result set than break down to several small result sets. I guess that the later approach requires more database traffics. But I have another situation that requires to process data from multiple tables. If I have all data (about 10,000 rows) in one result set, the process will be very very slower after about 1000 rows being processed. So I have to divide the data in smaller groups (1000 rows per group). Any general rules? suggestions? 2) After I processed about 1000 records at a time. my con.close(); statement will take about 5 minutes to complete. It seems that the system has to do something else before the connection will able to be closed, what is that? One more thing, I was monitoring the AS/400 active jobs while I run the Java program. I noticed that my JAVA job QZDASOINIT did not end even my program had completed closed the connection. The job QZDASOINIT was still running for about another 5-8 minutes. I am very new to AS/400. I guess that AS/400 has to clean up some resources before ending the job. Does anyone know why? How could I find out what AS/400 does before it ends the job? Weining (Wayne) Xu ALICO Information Systems & Technology Wilmington, DE. USA Phone: +302.594.2846 Fax: +302.594.2215 Email: weining.xu@aig.com +--- | This is the JAVA/400 Mailing List! | To submit a new message, send your mail to JAVA400-L@midrange.com. | To subscribe to this list send email to JAVA400-L-SUB@midrange.com. | To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com. | Questions should be directed to the list owner: joe@zappie.net +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.