Re: [INTERFACES] Inserting using SQL descriptors in ECPG indifferent versions of Linux - Mailing list pgsql-interfaces

From Michael Meskes
Subject Re: [INTERFACES] Inserting using SQL descriptors in ECPG indifferent versions of Linux
Date
Msg-id 1506847463.2588.50.camel@postgresql.org
Whole thread Raw
In response to [INTERFACES] Inserting using SQL descriptors in ECPG in different versions of Linux  (Anders Nilsson <anders.nilsson@noaa.gov>)
Responses Re: [INTERFACES] Inserting using SQL descriptors in ECPG in differentversions of Linux  (Anders Nilsson <anders.nilsson@noaa.gov>)
List pgsql-interfaces
> The following code compiles and runs fine without error messages on
> the Centos-6 box, but on the Centos-7 box, the execution of the
> prepared query with descriptor returns successful but without
> inserting any records and displaying the "No record actually
> inserted" message. Set PGUSER/PGDATABASE accordingly to run.

No idea why the same ecpg version behaves differently on these two
boxes. I assume that not both have the same version installed by
default, meaning you installed a non-default PostgreSQL yourself. Maybe
there was something left from the distro provided version?

> Any idea what I might be doing wrong?

Yes.

>     // Insert record
>     exec sql execute sid1 using descriptor insert_desc;

If my memory serves well, this should be "exec sql
execute sid1 using sql descriptor insert_desc;"

Without the SQL it tries to insert the sqlda which does not exist.

Michael
--
Michael Meskes
Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
Meskes at (Debian|Postgresql) dot Org
Jabber: michael at xmpp dot meskes dot org
VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL


--
Sent via pgsql-interfaces mailing list (pgsql-interfaces@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-interfaces

pgsql-interfaces by date:

Previous
From: Anders Nilsson
Date:
Subject: [INTERFACES] Inserting using SQL descriptors in ECPG in different versions of Linux
Next
From: Anders Nilsson
Date:
Subject: Re: [INTERFACES] Inserting using SQL descriptors in ECPG in differentversions of Linux