| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> |
| Cc: | Andrew Dunstan <andrew(at)dunslane(dot)net>, Chapman Flack <chap(at)anastigmatix(dot)net>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | Re: The "char" type versus non-ASCII characters |
| Date: | 2022-07-13 21:24:21 |
| Message-ID: | 2537044.1657747461@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
I wrote:
> Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> writes:
>> I think we could consider char to be a single-byte bytea and use the
>> escape format of bytea for char. That way there is some precedent and
>> we don't add yet another encoding or escape format.
> Do you want to take that as far as changing backslash to print
> as '\\' ?
This came up again today [1], so here's a concrete proposal.
Let's use \ooo for high-bit-set chars, but keep backslash as just
backslash (so it's only semi-compatible with bytea).
regards, tom lane
| Attachment | Content-Type | Size |
|---|---|---|
| change-char-type-io-format-1.patch | text/x-diff | 4.0 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2022-07-13 21:25:02 | Re: Bug: Reading from single byte character column type may cause out of bounds memory reads. |
| Previous Message | Andrew Dunstan | 2022-07-13 20:49:01 | Re: proposal: possibility to read dumped table's name from file |