Re: Why format() adds double quote? - Mailing list pgsql-hackers

From Tatsuo Ishii
Subject Re: Why format() adds double quote?
Date
Msg-id 20160127.104057.154346136736149633.t-ishii@sraoss.co.jp
Whole thread Raw
In response to Re: Why format() adds double quote?  ("Dickson S. Guedes" <listas@guedesoft.net>)
Responses Re: Why format() adds double quote?
List pgsql-hackers
> Thanks for advocate, I see here that it even produces that output with
> simple spaces.
>
> postgres=# create table x ("aí      " text);
> CREATE TABLE
> postgres=# \d x
>         Tabela "public.x"
>   Coluna  | Tipo | Modificadores
> ----------+------+---------------
>  aí       | text |
>
>
> This will break copy&paste user actions and scripts that parses that output.
>
> Maybe the patch should consider left/right non-printable chars to
> choose whether to show or not the " ?

This is a totally different story from the topic discussed in this
thread. psql never adds double quotations to column name even with
upper case col names.

test=# create table t6("ABC" int);
CREATE TABLE
test=# \d t6     Table "public.t6"Column |  Type   | Modifiers
--------+---------+-----------ABC    | integer |

If you want to change the existing psql's behavior, propose it
yourself.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp



pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Speedup twophase transactions
Next
From: Tatsuo Ishii
Date:
Subject: Re: Why format() adds double quote?