Re: pg 12 \if unwanted message

From: Holger Jakobs <holger(at)jakobs(dot)com>
To: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Re: pg 12 \if unwanted message
Date: 2022-07-29 10:38:47
Message-ID: e0188242-c70a-f4b7-bfab-0921cacfab8e@jakobs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin


Am 28.07.22 um 16:45 schrieb Pascal CROZET:
> Hi postgresql community,
>
> I've this message "command ignored" on false in \if \else \endif. How
> can passthrough this ?
>
> postgres(at)postgres# \echo :SERVER_VERSION_NAME
> 12.11 (Ubuntu 12.11-0ubuntu0.20.04.1)
>
> postgres(at)postgres# \if 1 \echo 'ONE' \else \echo 'NOT ONE' \endif
> ONE
> \echo command ignored; use \endif or Ctrl-C to exit current \if block
>
> postgres(at)postgres# \if 0 \echo 'ONE' \else \echo 'NOT ONE' \endif
> \echo command ignored; use \endif or Ctrl-C to exit current \if block
> NOT ONE
>
> *_________________________________*
>
> Cordialement,*Pascal CROZET*
>
> *DBA** -***METANEXT <http://www.metanext.com>, Think, Build, Run the Cloud
>
> **•www.metanext.com <http://www.metanext.com>•04 78 22 74 90
>
>
Hi Pascal,

This message only appears if you execute these statements one by one
interactively. When reading them from a file, no hint regarding the open
if branch is given.

Setting QUIET to 0 or client_min_messages to error doesn't suppress the
messing in interactive mode, unfortunately.

Best Regards,

Holger

--
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message David G. Johnston 2022-07-29 12:26:44 Re: Postgres Updating only changed columns against entire row
Previous Message Ron 2022-07-29 06:32:53 Re: Postgres Updating only changed columns against entire row