From: Matthias Apitz <guru@unixarea.de>
To: pgsql-general@lists.postgresql.org
Subject: ECPG sqlca error handling
Date: Thu, 12 Nov 2020 08:07:10 +0100
Message-ID: <20201112070710.GA18127@r314251-amd64> (raw)
Hello,
The documentation explains well how to use the 'sqlca' for error
handling: https://www.postgresql.org/docs/13/ecpg-errors.html#ECPG-SQLCA
An error message is stored in sqlca.sqlerrm.char sqlerrmc[SQLERRMC_LEN].
My question is: Is there some way to get the exact failing ESQL/C
statement, because only the line number does not help in our case.
Thanks in advance
matthias
--
Matthias Apitz, ✉ guru@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
Без книги нет знания, без знания нет коммунизма (Влaдимир Ильич Ленин)
Without books no knowledge - without knowledge no communism (Vladimir Ilyich Lenin)
Sin libros no hay saber - sin saber no hay comunismo. (Vladimir Ilich Lenin)
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: guru@unixarea.de
Subject: Re: ECPG sqlca error handling
In-Reply-To: <20201112070710.GA18127@r314251-amd64>
References: <20201112070710.GA18127@r314251-amd64>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox