Re: Add \pset options for boolean value display

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>
Cc: Álvaro Herrera <alvherre(at)kurilemu(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Add \pset options for boolean value display
Date: 2025-10-21 02:48:04
Message-ID: CAKFQuwYycabxpvPx-o6Q1WKy5Ph4PFiYrKoDQQT7TaL1gT+5jw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Monday, October 20, 2025, David G. Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
wrote:

> On Monday, October 20, 2025, Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> wrote:
>
>> The other thing I am thinking is that, with this patch, users are allowed
>> to display arbitrary strings for true/false, if a user mistakenly set
>> display_true to f and display_false to t, which will load to
>> misunderstanding.
>>
>
> Sympathetic to the concern but opposed to taking on such responsibility.
> They could probably modify their own query to do that if they really wanted
> to fool someone and I’m having trouble accepting this happening by
> accident. Do we test for yes/no; oui/non (i.e., foreign language choices);
> checkmark/X?
>
>
Actually, preventing t/f makes sense to me. Prevents a “hacker” from
messing with the default outputs in a hard-to-identify manner. Any other
value would point to pset being used.

David J.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Chao Li 2025-10-21 02:51:28 Re: Add \pset options for boolean value display
Previous Message David G. Johnston 2025-10-21 02:29:11 Re: Add \pset options for boolean value display