From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Thiemo Kellner <thiemo@gelassene-pferde.biz>
Cc: PostgreSQL General <pgsql-general@lists.postgresql.org>
Subject: Re: Use of ?get diagnostics'?
Date: Sat, 21 Sep 2019 09:21:06 +0100
Message-ID: <875zlmoyg5.fsf@news-spur.riddles.org.uk> (raw)
In-Reply-To: <20190921075700.Horde.7M0WmarMSSL6-CZvUSrg4Dg@webmail.gelassene-pferde.biz>
References: <20190921075700.Horde.7M0WmarMSSL6-CZvUSrg4Dg@webmail.gelassene-pferde.biz>
>>>>> "Thiemo" == Thiemo Kellner <thiemo@gelassene-pferde.biz> writes:
Thiemo> Hi all
Thiemo> I try to create a function (code at
Thiemo> https://pastebin.com/mTs18B90)
Paste sites are for IRC, on the mailing list you should always attach
the necessary details to your message.
Thiemo> using 'get diagnostics' to retrieve the number of affected
Thiemo> rows. However, it throws
Thiemo> the following exception was thrown:
Thiemo> SQLSTATE: 42703
Thiemo> column "row_count" does not exist
line 44 of your paste: V_TEXT := V_TEXT || ROW_COUNT || ' row.';
should be V_ROW_COUNT, I suspect. Likewise line 46.
(The CONTEXT lines of the error message would have identified the
offending line of the function for you.)
--
Andrew (irc:RhodiumToad)
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: andrew@tao11.riddles.org.uk, thiemo@gelassene-pferde.biz
Subject: Re: Use of ?get diagnostics'?
In-Reply-To: <875zlmoyg5.fsf@news-spur.riddles.org.uk>
References: <20190921075700.Horde.7M0WmarMSSL6-CZvUSrg4Dg@webmail.gelassene-pferde.biz> <875zlmoyg5.fsf@news-spur.riddles.org.uk>
* 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