public inbox for [email protected]  
help / color / mirror / Atom feed
From: Anders Nilsson <[email protected]>
To: Michael Meskes <[email protected]>
Cc: [email protected]
Subject: Re: Inserting using SQL descriptors in ECPG in different versions of Linux
Date: Mon, 2 Oct 2017 09:14:05 -0500
Message-ID: <CAEx11v5rQFjtsR4ZSxnT2uQSD2Z+Hd9SYLK=aD03DDdQWBTSeg@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
References: <CAEx11v5ScGENAcDVfMVuKMaBMMGkdrdqtSgAmfF_NaBihKkY+g@mail.gmail.com>
	<[email protected]>
List-Unsubscribe:  <mailto:[email protected]?body=unsub%20pgsql-interfaces>

Adding the SQL keyword fixed it! And, I was able to remove that dummy
insert_desc variable declaration above.

Thanks for your help,
Anders

On Sun, Oct 1, 2017 at 3:44 AM, Michael Meskes <[email protected]>
wrote:

> > 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
>
>


view thread (3+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: Inserting using SQL descriptors in ECPG in different versions of Linux
  In-Reply-To: <CAEx11v5rQFjtsR4ZSxnT2uQSD2Z+Hd9SYLK=aD03DDdQWBTSeg@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox