Re: BUG #16059: Tab-completion of filenames in COPY commands removes required quotes

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org, steven(dot)winfield(at)cantabcapital(dot)com
Subject: Re: BUG #16059: Tab-completion of filenames in COPY commands removes required quotes
Date: 2020-01-23 13:46:08
Message-ID: d746fc4c-c47d-2581-e9b2-641b05e350e5@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On 2020-01-14 02:38, Tom Lane wrote:
> I wrote:
>> Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> writes:
>>> I have found a weird behavior with identifier quoting, which is not the
>>> subject of this patch, but it appears to be affected by it.
>
>> I'll think about how to improve this. Given that we're dequoting
>> filenames explicitly anyway, maybe we don't need to tell readline that
>> double-quote is a quoting character. Another idea is that maybe
>> we ought to refactor things so that identifier dequoting and requoting
>> is handled explicitly, similarly to the way filenames work now.
>> That would make the patch a lot bigger though.
>
> On reflection, it seems like the best bet for the moment is to
> remove double-quote from the rl_completer_quote_characters string,
> which should restore all behavior around double-quoted strings to
> what it was before. (We have to keep single-quote in that string,
> though, or quoted file names fail entirely.)

This patch (version 6) looks good to me.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2020-01-23 14:43:33 Re: Query will execute when inner query have issue
Previous Message srinivasulu 2020-01-23 12:10:31 RE: BUG #16227: Loss database tables automatically in a couple of days

Browse pgsql-hackers by date

  From Date Subject
Next Message Christoph Berg 2020-01-23 14:09:53 Re: libxml2 is dropping xml2-config
Previous Message Fujii Masao 2020-01-23 13:14:48 Re: table partitioning and access privileges