Re: BUG #6254: COPY ... TO .. CSV sometimes doesn't escape strings

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Andrew Kerr <andrew(dot)kerr(at)unrulymedia(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #6254: COPY ... TO .. CSV sometimes doesn't escape strings
Date: 2011-10-13 20:31:31
Message-ID: 201110132031.p9DKVVM03514@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Andrew Kerr wrote:
>
> The following bug has been logged online:
>
> Bug reference: 6254
> Logged by: Andrew Kerr
> Email address: andrew(dot)kerr(at)unrulymedia(dot)com
> PostgreSQL version: 9.0.5
> Operating system: CentOS 5.4
> Description: COPY ... TO .. CSV sometimes doesn't escape strings
> Details:
>
> Query of this form:
>
> copy (select
> col1,col2
> from mytable)
> to 'output.csv' with (format csv, force_quote *);
>
> where some selected columns are text sometimes fails to escape quotes (with
> another quote) in text.
>
> On which rows this happens varies with different runs.
>
> Sometimes a field will have some quotes escaped and some not.
>
> Running on a 90 million row table.

Please show us an example.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ It's impossible for everything to be true. +

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Bruce Momjian 2011-10-14 01:37:03 Re: Re: BUG #6050: Dump and restore of view after a schema change: can't restore the view
Previous Message Bruce Momjian 2011-10-13 17:09:07 Re: [BUGS] BUG #6034: pg_upgrade fails when it should not.