X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 9663E566C4 for ; Sat, 12 Mar 2005 05:21:29 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 03593-05 for ; Sat, 12 Mar 2005 05:21:25 +0000 (GMT) Received: from mail26.sea5.speakeasy.net (mail26.sea5.speakeasy.net [69.17.117.28]) by svr1.postgresql.org (Postfix) with ESMTP id 85BA6566B2 for ; Sat, 12 Mar 2005 05:21:21 +0000 (GMT) Received: (qmail 27672 invoked from network); 12 Mar 2005 05:21:21 -0000 Received: from dsl093-096-062.wdc2.dsl.speakeasy.net (HELO emach) (guy-rouillier@[66.93.96.62]) (envelope-sender ) by mail26.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 12 Mar 2005 05:21:20 -0000 Date: Fri, 11 Mar 2005 19:21:34 -0500 From: Guy Rouillier To: PostgreSQL JDBC Subject: Calling stored functions in executeBatch Message-ID: <20050311192134.6aad0052@emach> X-Mailer: Sylpheed-Claws 1.0.0cvs7.1 (GTK+ 2.4.13; x86_64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200503/128 X-Sequence-Number: 12520 I've browsed the archives and understand that I am not supposed to submit SELECT statements in batch. I'm converting some code from Oracle that invokes stored procedures via batch (for high volume inserts.) I've got the stored proc converted, but invoking in batch using "select my_proc(x,y,z)" produces the predictable "result not expected", even though my stored proc returns VOID. Is there any way I can absorb the return value from the select to prevent this error? I'd like to avoid rewriting this code as I want it to continue to run with Oracle until I successfully sell the conversion idea. I'm able to do this so far by changing the SQL statements to be INVOKE + "my_proc(x,y,z)" and then just setting INVOKE to either "call" or "select" for Oracle and PostgreSQL, respectively. Will I run into the same problem if I change these SQL statements to use the call escape format? Thanks. -- Guy Rouillier