Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 5AC6D9FB85F for ; Mon, 7 May 2007 10:01:43 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 24979-09-2 for ; Mon, 7 May 2007 10:01:32 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.247]) by postgresql.org (Postfix) with ESMTP id B888C9FB856 for ; Mon, 7 May 2007 10:01:36 -0300 (ADT) Received: by an-out-0708.google.com with SMTP id d17so109945and for ; Mon, 07 May 2007 06:01:35 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=FXVF9EK//M4mAWxXCqSX2Bax/jwTcQ+/bVCO3UMGyoWVAukHF6GjWvdNyTRrNGore/bPvxOgqe2aYnVBXbKXzo43HN7VhiNAO73+PE+4BJvIDsU8t3fdUa7zSNK1n2wsihc8Dwu6xSSphwhFx22gzXKB+I40qZao2WrSKhBR5Bc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=rywicPehOTHSxpDbgmw5H5K/iNQYLLNutH3tUABL6CedPx8gHojyFekNE6Ur4Kkfw+4N+KzNcJFzonRNjDM0oinutGiWQ4AU6f8rRd0OltNBKG4IlzNKVt8G7gOg84+iPIf4pFklcqPj/CONaPSByDuUA4zw+0yw6mA/Dws7ckY= Received: by 10.100.78.19 with SMTP id a19mr2163311anb.1178542894009; Mon, 07 May 2007 06:01:34 -0700 (PDT) Received: by 10.100.216.9 with HTTP; Mon, 7 May 2007 06:01:33 -0700 (PDT) Message-ID: <4478b4ac0705070601w7d8584eev6923c750376018e6@mail.gmail.com> Date: Mon, 7 May 2007 18:31:33 +0530 From: "Kranti Parisa" To: "Dave Cramer" Subject: Re: Problem with Utilizing executeBatch() with stored procedures Cc: pgsql-jdbc@postgresql.org, guyr-ml1@burntmail.com In-Reply-To: <4072DC0A-204E-4CA8-ACA8-2033FF43726C@fastcrypt.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_90952_12380158.1178542893924" References: <4478b4ac0705070056p469415d7ib6a1e746de7a0921@mail.gmail.com> <76AE553D-DCEA-4623-B78B-CD6BED35EB49@fastcrypt.com> <4478b4ac0705070408s7a09a038w5d7f846f3f6fb20e@mail.gmail.com> <4478b4ac0705070446j535baa1aye2596424ba87ebbe@mail.gmail.com> <4478b4ac0705070553l71f23617m429e65ef6bbdadc6@mail.gmail.com> <4072DC0A-204E-4CA8-ACA8-2033FF43726C@fastcrypt.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200705/31 X-Sequence-Number: 17021 ------=_Part_90952_12380158.1178542893924 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi, I am getting the following >>>>>>>>>>>>>>>>>>> PostgreSQL 8.2 JDBC3 with SSL (build 505) On 5/7/07, Dave Cramer wrote: > > What does the output of > org.postgresql.Driver.getVersion() > > display ? > > > On 7-May-07, at 8:53 AM, Kranti Parisa wrote: > > Hi, > > Yes i added the jar file as external jar in Eclipse. > > Please find the screen shot in the attachment > > Regards > Kranti > > On 5/7/07, Dave Cramer wrote: > > > > Are you absolutely sure that you have the correct driver in the > > classpath. The latest source has my code in it. > > Dave > > On 7-May-07, at 7:46 AM, Kranti Parisa wrote: > > > > Hi, > > > > I downloaded the driver from the following link > > > > http://jdbc.postgresql.org/download.html > > > > and trying to write the following code in my test class in Eclipse > > > > CallableStatement cstmt = null; > > try { > > cstmt = con.prepareCall("{?=call test_cal_batch()}"); > > cstmt.registerOutParameter(1, Types.INTEGER); > > cstmt.addBatch (); > > cstmt.executeBatch(); > > //Object rs = cstmt.getObject(1); > > / > > } catch (SQLException e) { > > // TODO Auto-generated catch block > > System.out.println(e.getNextException ()); > > } > > > > getting the following error > > > > org.postgresql.util.PSQLException: A result was returned when none was > > expected. > > > > Please suggest me some steps > > > > Regards > > Kanti > > > > On 5/7/07, Dave Cramer < pg@fastcrypt.com> wrote: > > > > > > The latest released version is 8.2-505, this is what you want, and it > > > will work with an 8.1 server. > > > Dave > > > On 7-May-07, at 7:08 AM, Kranti Parisa wrote: > > > > > > Hi, > > > > > > I am using the following driver with PostgreSQL 8.1 version > > > > > > postgresql-8.1-406.jdbc3.jar > > > > > > Please let me know if the version is correct. > > > > > > Regards > > > Kranti > > > > > > On 5/7/07, Dave Cramer < pg@fastcrypt.com> wrote: > > > > > > > > It's been fixed in the lastest version. > > > > > > > > > > > > Dave > > > > On 7-May-07, at 3:56 AM, Kranti Parisa wrote: > > > > > > > > > Hi, > > > > > > > > > > I saw few threads about this topic, but not able to get the > > > > > solution. Please help me how can we solve this problem. > > > > > I have a stored procedure which has to execute for all the given > > > > > employee ids. so i want to do that as a batch to get performance. > > > > > > > > > > but i am getting this error > > > > > > > > > > org.postgresql.util.PSQLException : A result was returned when > > > > none > > > > > was expected > > > > > > > > > > A million thanks in advance.. > > > > > Hoping for a quick reply > > > > > > > > > > ------------------ > > > > > Best Regards > > > > > Kranti Kiran Kumar Parisa > > > > > > > > > > > > > > > > > > > > > > -- > > > ------------------ > > > Best Regards > > > Kranti Kiran Kumar Parisa > > > Mobile: +91 - 9849 - 625 - 625 +91 - 9391 - 438 - 738 > > > > > > > > > > > > > > > -- > > ------------------ > > Best Regards > > Kranti Kiran Kumar Parisa > > Mobile: +91 - 9849 - 625 - 625 +91 - 9391 - 438 - 738 > > > > > > > > > -- > ------------------ > Best Regards > Kranti Kiran Kumar Parisa > Mobile: +91 - 9849 - 625 - 625 +91 - 9391 - 438 - 738 > > > > -- ------------------ Best Regards Kranti Kiran Kumar Parisa Mobile: +91 - 9849 - 625 - 625 +91 - 9391 - 438 - 738 ------=_Part_90952_12380158.1178542893924 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi,

I am getting the following

>>>>>>>>>>>>>>>>>>> PostgreSQL 8.2 JDBC3 with SSL (build 505)




On 5/7/07, Dave Cramer <pg@fastcrypt.com> wrote:
What does the output of 

org.postgresql.Driver.getVersion() 

display ?


On 7-May-07, at 8:53 AM, Kranti Parisa wrote:

Hi,

Yes i added the jar file as external jar in Eclipse.

Please find the screen shot in the attachment

Regards
Kranti

On 5/7/07, Dave Cramer <pg@fastcrypt.com > wrote:
Are you absolutely sure that you have the correct driver in the classpath. The latest source has my code in it.

Dave

On 7-May-07, at 7:46 AM, Kranti Parisa wrote:

Hi,

I downloaded the driver from the following link

http://jdbc.postgresql.org/download.html

and trying to write the following code in my test class in Eclipse

CallableStatement cstmt = null;
        try {
            cstmt = con.prepareCall("{?=call test_cal_batch()}");
            cstmt.registerOutParameter(1, Types.INTEGER);
            cstmt.addBatch ();
            cstmt.executeBatch();
            //Object rs = cstmt.getObject(1);
/
        } catch (SQLException e) {
            // TODO Auto-generated catch block
            System.out.println(e.getNextException ());
        }

getting the following error

org.postgresql.util.PSQLException: A result was returned when none was expected.

Please suggest me some steps

Regards
Kanti

On 5/7/07, Dave Cramer < pg@fastcrypt.com> wrote:
The latest released version is 8.2-505, this is what you want, and it will work with an 8.1 server.

Dave

On 7-May-07, at 7:08 AM, Kranti Parisa wrote:

Hi,

I am using the following driver with PostgreSQL 8.1 version

postgresql-8.1-406.jdbc3.jar

Please let me know if the version is correct.

Regards
Kranti

On 5/7/07, Dave Cramer < pg@fastcrypt.com> wrote:
It's been fixed in the lastest version.


Dave
On 7-May-07, at 3:56 AM, Kranti Parisa wrote:

> Hi,
>
> I saw few threads about this topic, but not able to get the
> solution. Please help me how can we solve this problem.
> I have a stored procedure which has to execute for all the given
> employee ids. so i want to do that as a batch to get performance.
>
> but i am getting this error
>
> org.postgresql.util.PSQLException : A result was returned when none
> was expected
>
> A million thanks in advance..
> Hoping for a quick reply
>
> ------------------
> Best Regards
> Kranti Kiran Kumar Parisa
>




--
------------------
Best Regards
Kranti Kiran Kumar Parisa
Mobile: +91 - 9849 - 625 - 625             +91 - 9391 - 438 - 738




--
------------------
Best Regards
Kranti Kiran Kumar Parisa
Mobile: +91 - 9849 - 625 - 625             +91 - 9391 - 438 - 738




--
------------------
Best Regards
Kranti Kiran Kumar Parisa
Mobile: +91 - 9849 - 625 - 625             +91 - 9391 - 438 - 738
<postgresql.JPG>




--
------------------
Best Regards
Kranti Kiran Kumar Parisa
Mobile: +91 - 9849 - 625 - 625             +91 - 9391 - 438 - 738 ------=_Part_90952_12380158.1178542893924--