| From: | chenhj <chjischj(at)163(dot)com> |
|---|---|
| To: | pgsql-bugs(at)postgresql(dot)org |
| Subject: | psql treat backslash which is not the first character in the input line as meta-command |
| Date: | 2014-10-29 09:09:01 |
| Message-ID: | 2c11ec45.d072.1495b2a551b.Coremail.chjischj@163.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs |
Hi,all
psql treat backslash which is not the first character in the input line as meta-command,and failed to execute the next query.
It seems to be a bug.
Sample1:
postgres=# select \1 set c2=c1%3 ;
Invalid command \1. Try \? for help.
postgres-# select 1;
ERROR: syntax error at or near "select"
LINE 2: select 1;
^
Sample2:
postgres=# a \l
List of databases
Name | Owner | Encoding | Collate | Ctype | Access privileges
-----------+--------+-----------+------------+------------+-------------------
postgres | chenhj | SQL_ASCII | C | C |
template0 | chenhj | SQL_ASCII | C | C | =c/chenhj +
| | | | | chenhj=CTc/chenhj
template1 | chenhj | SQL_ASCII | C | C | =c/chenhj +
| | | | | chenhj=CTc/chenhj
(6 rows)
postgres-# select 1;
ERROR: syntax error at or near "a"
LINE 1: a
^
Regards,
Chen Huajun
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Pavel Stehule | 2014-10-29 09:25:23 | Re: psql treat backslash which is not the first character in the input line as meta-command |
| Previous Message | Éric Quinton | 2014-10-29 08:47:37 | bad result from too large number of rows in imbricated requests |