Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k6pmT-0003bY-Dc for pgsql-general@arkaria.postgresql.org; Sat, 15 Aug 2020 06:35:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k6pmS-0000OZ-2O for pgsql-general@arkaria.postgresql.org; Sat, 15 Aug 2020 06:35:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k6pmR-0000OS-P2 for pgsql-general@lists.postgresql.org; Sat, 15 Aug 2020 06:35:03 +0000 Received: from mxout2.rambler.ru ([81.19.78.101]) by magus.postgresql.org with esmtps (TLS1.1:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.92) (envelope-from ) id 1k6pmQ-00035X-6R for pgsql-general@postgresql.org; Sat, 15 Aug 2020 06:35:03 +0000 Received: from saddam3.rambler.ru (saddam3.rambler.ru [10.32.16.3]) by mxout2.rambler.ru (Postfix) with ESMTP id 1B74A8DC13D; Sat, 15 Aug 2020 09:35:01 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rambler.ru; s=mail; t=1597473301; bh=X6hB7h2hYBQU3yEBWbl0XsN3O73hc94WqM7fjx4q/qA=; h=From:To:Cc:Reply-To:Subject:Date:In-Reply-To:References; b=nn4iVw1ZbebaWw4goPCCKjWz0qDj+OsOU1/5nEPR48oHJu5rswFzFFSNkJW4uoDf3 Y//xzWB7WeW8NLIIdCB0KtSPQ48hCSiQRwtoXx2jUb7VMQIM5vNnJR+WPFPiT36B5J w7StliEBLd3nZ2vRnySGOk80qBXuzsxFEN9DUnSc= Received: from localhost.localdomain (localhost [127.0.0.1]) by saddam3.rambler.ru (Postfix) with ESMTP id F37B8C4B64D; Sat, 15 Aug 2020 09:35:00 +0300 (MSK) Received: from [93.123.182.191] by mail.rambler.ru with HTTP; Sat, 15 Aug 2020 09:35:00 +0300 From: "Aleksey M Boltenkov" To: pavel.stehule@gmail.com Cc: "pgsql-general" Reply-To: "Aleksey M Boltenkov" Subject: RE: bug in psql? Date: Sat, 15 Aug 2020 09:35:00 +0300 Content-Transfer-Encoding: 7bit Content-Type: multipart/alternative; boundary="_----------=_15974733001490353" In-Reply-To: Message-Id: <1597473300.936394.14903.9328@mail.rambler.ru> MIME-Version: 1.0 References: X-Mailer: Rambler WebMail, http://mail.rambler.ru/ X-Rambler-User: holybolt@rambler.ru/93.123.182.191 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --_----------=_15974733001490353 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8"; format="flowed" eksey M Boltenkov. 15.08.2020, 08:39, Pavel Stehule so 15. 8. 2020 v 7:35 odes=C3=ADlatel Aleksey M Boltenkov napsal: Is this a bug? Executing of malformed (quote symbols) select in psql results in unexpected behaviour: pg01:5432 postgres@db=3D# select 'any expression'any expression\d+; List of relations Schema =E2=94=82 Name =E2=94=82 Type =E2=94=82 Owner =E2=94=82 Size =E2= =94=82 Description =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90 public =E2=94=82 geography_columns =E2=94=82 view =E2=94=82 postgres = =E2=94=82 0 bytes =E2=94=82 public =E2=94=82 geometry_columns =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82 public =E2=94=82 pg_buffercache =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82 public =E2=94=82 pg_stat_statements =E2=94=82 view =E2=94=82 postgres = =E2=94=82 0 bytes =E2=94=82 public =E2=94=82 raster_columns =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82 public =E2=94=82 raster_overviews =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82 public =E2=94=82 spatial_ref_sys =E2=94=82 table =E2=94=82 postgres =E2= =94=82 4616 kB =E2=94=82 ... I tested psql-12 and psql-14 and I don't see this issue Pavel Aleksey M Boltenkov. You must have relations in search path, ifaiu. engineer@pg02:~$ psql -U postgres -h localhost -p 5432 kaad SET Timing is on. Null display is "=C2=A4". Line style is unicode. Unicode border line style is "single". Unicode column line style is "single". Unicode header line style is "double". Output format is wrapped. SET Time: 0.234 ms SET Time: 0.206 ms psql (12.4 (Ubuntu 12.4-1.pgdg18.04+1)) Type "help" for help.2020-08-15 09:29:18 localhost:5432 postgres@kaad=3D# s= elect version(); version =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90 PostgreSQL 12.4 (Ubuntu 12.4-1.pgdg18.04+1) on x86_64-pc-linux-gnu, compile= d by gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0, 64-bit (1 row)Time: 6.682 ms 2020-08-15 09:29:24 localhost:5432 postgres@kaad=3D# select 'any expression= 'any expression\d+; List of relations Schema =E2=94=82 Name =E2=94=82 Type =E2=94=82 Owner =E2=94=82 Size =E2=94= =82 Description =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90 public =E2=94=82 geography_columns =E2=94=82 view =E2=94=82 postgres =E2=94= =82 0 bytes =E2=94=82 public =E2=94=82 geometry_columns =E2=94=82 view =E2=94=82 postgres =E2=94= =82 0 bytes =E2=94=82 public =E2=94=82 raster_columns =E2=94=82 view =E2=94=82 postgres =E2=94=82= 0 bytes =E2=94=82 public =E2=94=82 raster_overviews =E2=94=82 view =E2=94=82 postgres =E2=94= =82 0 bytes =E2=94=82 public =E2=94=82 spatial_ref_sys =E2=94=82 table =E2=94=82 postgres =E2=94= =82 4616 kB =E2=94=82 (5 rows)[more] - > ; -- semicolon is manually added ERROR: 42601: syntax error at or near "any" LINE 1: select 'any expression'any expression ^ LOCATION: scanner_yyerror, scan.l:1149 Time: 0.530 ms Aleksey M Boltenkov. --_----------=_15974733001490353 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset="utf-8"
eksey M Boltenkov.

15.08.2020, 08= :39, Pavel Stehule <pavel.stehule@gmail.com>

so 15. 8. 2020 v 7:35 odes=C3=ADlatel Aleksey M Boltenkov &l= t;holybolt@= rambler.ru> napsal:
Is this a bug?

Executing of malformed (quote symbols) select in psql results in u= nexpected behaviour:

pg01:5432 postgres@db=3D# sel= ect 'any expression'any expression\d+;
List of relations
Schema =E2= =94=82 Name =E2=94=82 Type =E2=94=82 Owner =E2=94=82 Size =E2=94=82 Descrip= tion
=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90
public =E2=94=82 geography_columns =E2=94=82 v= iew =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82
public =E2=94=82 geo= metry_columns =E2=94=82 view =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82=
public =E2=94=82 pg_buffercache =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82
public =E2=94=82 pg_stat_statements =E2=94=82 = view =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82
public =E2=94=82 ra= ster_columns =E2=94=82 view =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82<= br> public =E2=94=82 raster_overviews =E2=94=82 view =E2=94=82 postgres =E2= =94=82 0 bytes =E2=94=82
public =E2=94=82 spatial_ref_sys =E2=94=82 tab= le =E2=94=82 postgres =E2=94=82 4616 kB =E2=94=82
...

I tested psql-12 and psql-14 and I don't see= this issue

Pavel


=

Aleksey M Boltenkov.


You must have relations in se= arch path, ifaiu.

engineer@pg02:~$ psql -U postgre= s -h localhost -p 5432 kaad
SET
Timing is on.
Null display is "=C2= =A4".
Line style is unicode.
Unicode border line style is "single".Unicode column line style is "single".
Unicode header line style is "d= ouble".
Output format is wrapped.
SET
Time: 0.234 ms
SET
Tim= e: 0.206 ms
psql (12.4 (Ubuntu 12.4-1.pgdg18.04+1))
Type "help" for h= elp.
2020-08-15 09:29:18 localhost:5432 postgres@kaad=3D# select = version();
version
=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90
Postgre= SQL 12.4 (Ubuntu 12.4-1.pgdg18.04+1) on x86_64-pc-linux-gnu, compiled by gc= c (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0, 64-bit
(1 row)
Time: 6.= 682 ms
2020-08-15 09:29:24 localhost:5432 postgres@kaad=3D# select 'any = expression'any expression\d+;
List of relations
Schema =E2=94=82 Na= me =E2=94=82 Type =E2=94=82 Owner =E2=94=82 Size =E2=94=82 Description
= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2= =95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2=95=90=E2=95=90= =E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=AA=E2= =95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95= =90=E2=95=90=E2=95=90=E2=95=90=E2=95=90
public =E2=94=82 geography_colu= mns =E2=94=82 view =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82
publi= c =E2=94=82 geometry_columns =E2=94=82 view =E2=94=82 postgres =E2=94=82 0 = bytes =E2=94=82
public =E2=94=82 raster_columns =E2=94=82 view =E2=94= =82 postgres =E2=94=82 0 bytes =E2=94=82
public =E2=94=82 raster_overvi= ews =E2=94=82 view =E2=94=82 postgres =E2=94=82 0 bytes =E2=94=82
publi= c =E2=94=82 spatial_ref_sys =E2=94=82 table =E2=94=82 postgres =E2=94=82 46= 16 kB =E2=94=82
(5 rows)
[more] - > ; -- semicolon is manua= lly added
ERROR: 42601: syntax error at or near "any"
LINE 1: select = 'any expression'any expression
^
LOCATION: scanner_yyerror, scan.l:1= 149
Time: 0.530 ms

Ale= ksey M Boltenkov.

= --_----------=_15974733001490353--