BUG #1469: ECPG : Can't delete an item pointed by a cursor - Mailing list pgsql-bugs

From Anthony COMMUNIER
Subject BUG #1469: ECPG : Can't delete an item pointed by a cursor
Date
Msg-id 20050207234848.4E3F2F0B02@svr2.postgresql.org
Whole thread Raw
Responses Re: BUG #1469: ECPG : Can't delete an item pointed by a cursor  (Peter Eisentraut <peter_e@gmx.net>)
Re: BUG #1469: ECPG : Can't delete an item pointed by a cursor  (Michael Meskes <meskes@postgresql.org>)
List pgsql-bugs
The following bug has been logged online:

Bug reference:      1469
Logged by:          Anthony COMMUNIER
Email address:      anthony.communier@capgemini.fr
PostgreSQL version: 8.0.1
Operating system:   Aix 5.2,UnixWare 7.1.3,Win32
Description:        ECPG : Can't delete an item pointed by a cursor
Details:

The statement : EXEC SQL DELETE  FROM <table> WHERE CURRENT OF <cursor name>
(describe in SQL 99) isn't recognize by ecpg

Ecpg returns ERROR: syntax error at or near "CURRENT" for the following
program :


EXEC SQL DECLARE C3_NTF CURSOR FOR
    SELECT
        NUM_NOTIF,
        TYPE_NOTIF,
        NOTIFIE,
        ACTION,
        NB_NVX_MSG
    FROM
        DISPNTEL
    FOR UPDATE;

    EXEC  OPEN C3_NTF;

...

    for(;;)
    {
...

          EXEC SQL FETCH C3_NTF
        INTO :SAPnum_notif,
             :SAPtype_notif,
             :SAPnotifie:INDnotifie,
             :SAPaction:INDaction,
             :SAPnb_nvx_msg:INDnb_nvx_msg;

...
      EXEC SQL DELETE  FROM DISPNTEL WHERE CURRENT OF C3_NTF;

...

    }


The yacc grammar do not authorize the keywords CURRENT OF

pgsql-bugs by date:

Previous
From: "Lucas Galfaso"
Date:
Subject: Minor bug in pgAdmin III
Next
From: Michael Guerin
Date:
Subject: ERROR: cache lookup failed for relation 17442