Re: [JDBC] BatchUpdate exception
On Thu, 6 Dec 2007, Kranti K K Parisa [GetSet-India] wrote:
> for (int i=0;i<200;i++){ > //System.out.println("inside outer==>>"+i); > for(int j=0;j<4;j++){ > proc=null; > //System.out.println("inside inner==>>"+j); > proc=con.prepareCall("{call > client255271111.test_function()}"); > //proc.registerOutParameter(1, Types.INTEGER); > proc.addBatch(); > } > } > int []intUpdates=proc.executeBatch();
Since you're reinitializing proc inside the loop you only end up adding
one batch to it, so you only get one batch out.
Kris Jurka
---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at
http://www.postgresql.org/about/donate
Received on Thu Dec 6 04:40:07 2007
This archive was generated by hypermail 2.1.8
: Wed Jun 18 2008 - 23:40:59 EDT
|