Re: Handling of \ in array data display - Mailing list pgsql-bugs

From Josh Berkus
Subject Re: Handling of \ in array data display
Date
Msg-id 200608181607.07332.josh@agliodbs.com
Whole thread Raw
In response to Re: Handling of \ in array data display  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: Handling of \ in array data display  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
Alvaro,

> tarr[1] does not have a \, because it was eaten by the parser (so \y is
> the same as a plain y).  tarr[2] does have a single backslash, which for
> output purposes is shown escaped with another backslash when part of an
> array, but unescaped when not.  I'm not sure if this qualifies as a bug
> or not.

I think it does.   It's not consistent with how text values not in an array
are displayed.   The whole reason I reported it was because of a user
thinking their data wasn't being saved correctly, so it's causing
confusion.

FWIW, I personaly think we should be using the ARRAY[] format for display
anyway, but that would break some backwards compatibility ...

--
--Josh

Josh Berkus
PostgreSQL @ Sun
San Francisco

pgsql-bugs by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: Handling of \ in array data display
Next
From: Tom Lane
Date:
Subject: Re: Handling of \ in array data display