Re: pg_restore recognizing $-quotes

From: "Andrew Dunstan" <andrew(at)dunslane(dot)net>
To: <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: <pjw(at)rhyme(dot)com(dot)au>, <pgsql-patches(at)postgresql(dot)org>, <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: pg_restore recognizing $-quotes
Date: 2004-08-18 10:39:44
Message-ID: 3643.24.211.141.25.1092825584.squirrel@www.dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

Bruce Momjian said:
>
> This is quite a large patch, but we do need a solution to this problem.
> Should it be applied?
>
>

I looked at it briefly, but felt sufficiently daunted that I gave up until I
have time to review it (my time is extremely limited right now).

ISTM that a very simple alternative would be to force pg_dump to inhibit
dollar quoting for non-text dumps. Then we could revisit the issue later on,
and maybe bite the bullet and use flex in pg_restore.

cheers

andrew

---------------------------------------------------------------------------
>
> Philip Warner wrote:
>>
>> Not sure if this is the desired approach, but since it works, I
>> thought I'd send it.
>>
>> This patch allows pg_restore to recognize $-quotes in SQL queries. It
>> will treat any unquoted string that starts with a $ and has no
>> preceding identifier chars as a potential $-quote tag, it then makes
>> sure that the tag chars are valid. If so, it processes the $-quote.
>>
>> Tested against local DBs and regression DB.

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Philip Warner 2004-08-18 12:01:24 Re: pg_restore recognizing $-quotes
Previous Message Andreas Pflug 2004-08-18 10:32:24 Re: Compiling libpq with VC6