Search Postgresql Archives

Re: Method to detect certain characters in column?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ian Meyer wrote:
> That's entirely possible.. which is the reason for cleanup.. we're
> moving to a model where members can be queried by name, and UTF-8
> isn't allowed in URLs, so we need to rename/remove users with those
> types of names.

Depending on your webserver, Unicode characters should be possible in
URLs. Certainly some non-7-bit characters can be represented in URLs
with % encoding.

On my Apache system, for example, the string:

    áüÜć

in latin-1 encoding is represented in a URL as:

    %c3%a1%c3%bc%c3%9c%c4%87

If that same byte sequence is decoded as UTF-8 instead, it is:

    áüÜć

(a-acute u-umlaut U-umlaut c-acute)

In other words, you can send an arbitrary byte sequence in a URL with %
escapes. How that byte sequence is decoded into a sequence of characters
depends on your web server and its configuration - or, if the web server
sends the % encoded URL directly to your client, on how your client
chooses to interpret it.

The main trouble will be ensuring that clients and the server agree on
the character encoding used in the URL.

--
Craig Ringer


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux