Re: Facing issue in using special characters

From: Chapman Flack <chap(at)anastigmatix(dot)net>
To: Gunther <raj(at)gusw(dot)net>, M Tarkeshwar Rao <m(dot)tarkeshwar(dot)rao(at)ericsson(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Facing issue in using special characters
Date: 2019-03-15 19:26:50
Message-ID: 029370ff-c224-9e74-09f6-e70a178a9039@anastigmatix.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers pgsql-performance

On 3/15/19 11:59 AM, Gunther wrote:
> This is not an issue for "hackers" nor "performance" in fact even for
> "general" it isn't really an issue.

As long as it's already been posted, may as well make it something
helpful to find in the archive.

> Understand charsets -- character set, code point, and encoding. Then
> understand how encoding and string literals and "escape sequences" in
> string literals might work.

Good advice for sure.

> Know that UNICODE today is the one standard, and there is no more need

I wasn't sure from the question whether the original poster was in
a position to choose the encoding of the database. Lots of things are
easier if it can be set to UTF-8 these days, but perhaps it's a legacy
situation.

Maybe a good start would be to go do

SHOW server_encoding;
SHOW client_encoding;

and then hit the internet and look up what that encoding (or those
encodings, if different) can and can't represent, and go from there.

It's worth knowing that, when the server encoding isn't UTF-8,
PostgreSQL will have the obvious limitations entailed by that,
but also some non-obvious ones that may be surprising, e.g. [1].

-Chap

[1]
https://www.postgresql.org/message-id/CA%2BTgmobUp8Q-wcjaKvV%3DsbDcziJoUUvBCB8m%2B_xhgOV4DjiA1A%40mail.gmail.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Andreas Kretschmer 2019-03-15 20:02:29 Re: Conditional INSERT
Previous Message Michel Pelletier 2019-03-15 19:24:21 Re: Conditional INSERT

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2019-03-15 19:45:28 Re: hyrax vs. RelationBuildPartitionDesc
Previous Message Jeff Janes 2019-03-15 19:20:06 Re: GiST VACUUM

Browse pgsql-performance by date

  From Date Subject
Next Message Rory Campbell-Lange 2019-03-16 18:58:55 MDRaid or LSI MegaRAID?
Previous Message Michel Pelletier 2019-03-15 16:35:13 Re: jsonb_set performance degradation / multiple jsonb_set on multiple documents