Re: [INTERFACES] USE OF CURSORS IN ECPG

From: "Maurizio" <maurizio(dot)c(at)libero(dot)it>
To: "Michael Meskes" <meskes(at)postgresql(dot)org>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [INTERFACES] USE OF CURSORS IN ECPG
Date: 2000-11-09 13:49:29
Message-ID: 004301c04a53$f98ecc00$7394fea9@maurizio
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-interfaces

But, how can I do ?
I have to recall the same routine many times. I tried to prepare and declare
the cursor inside the routine but when I compile with ecpg I receive the
error Cursor already defined.

Maurizio

.
----- Original Message -----
From: "Michael Meskes" <meskes(at)postgresql(dot)org>
To: "Maurizio" <maurizio(at)dreamtech-it(dot)com>
Cc: <pgsql-interfaces(at)postgresql(dot)org>
Sent: Wednesday, November 08, 2000 12:39 PM
Subject: Re: [INTERFACES] USE OF CURSORS IN ECPG

> On Tue, Nov 07, 2000 at 05:52:00PM +0100, Maurizio wrote:
> > I'm just starded using ecpg and I have some problem with cursors.
> > ...
> > exec sql prepare stmtunimpianto from :query;
> > .
> > .
> > exec sql commit;
> > ...
> > If I rem the commit all works fine but if I execute the commit the
cursor was deleted and I receive some errors.
> >
> > At open cursor : sqlca.sqlcode = -230 Invalid statement namei in line
......
> > at fetch : NOTICE : PerformPortalFetch: portal
"cur_unimpianto" not found
>
> No surprise here as ending a transaction forces a deallocation of all
> prepared statements. AFAIK that's what the standard says.
>
> Michael
>
> --
> Michael Meskes
> Michael(at)Fam-Meskes(dot)De
> Go SF 49ers! Go Rhein Fire!
> Use Debian GNU/Linux! Use PostgreSQL!

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Don Baccus 2000-11-09 14:20:57 Re: Text concat problem
Previous Message Philip Warner 2000-11-09 13:08:22 Question about reliability?

Browse pgsql-interfaces by date

  From Date Subject
Next Message Dave Page 2000-11-09 21:54:53 RE: Access 2000 and empty fields
Previous Message Phil Davey 2000-11-09 12:15:07 Re: Access 2000 and empty fields