Lists: | Postg범퍼카 토토SQLpgsql-patches |
---|
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | SQL99 CONVERT() function |
Date: | 2002-08-06 05:55:04 |
Message-ID: | 20020806.145504.35027319.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | Postg범퍼카 토토SQL pgsql-patches |
I have added SQL99's CONVERT() function. docs and regression tests
also updated. Our own convert() functions can also be used. Example
usage of CONVERT():
convert('PostgreSQL' using iso8859_1_to_utf8)
will return 'PostgreSQL' in utf-8 encoding. See "String Functions and
Operators" section of Users's guide for more details and currently
available (predefined) conversions.
I believe remaining work for CONVERSION stuffs is some conversions for
cyrillic and win874/1250/1251/1256 encodings.
--
Tatsuo Ishii
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-06 06:57:35 |
Message-ID: | 20020806.155735.15253458.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> I believe remaining work for CONVERSION stuffs is some conversions for
> cyrillic and win874/1250/1251/1256 encodings.
Oops. I forgot the cygwin (and AIX) issue. Need to address it before
beta freeze...
--
Tatsuo Ishii
From: | Karel Zak <zakkr(at)zf(dot)jcu(dot)cz> |
---|---|
To: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-06 07:54:17 |
Message-ID: | 20020806095416.A9339@zf.jcu.cz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
On Tue, Aug 06, 2002 at 02:55:04PM +0900, Tatsuo Ishii wrote:
> I have added SQL99's CONVERT() function. docs and regression tests
> also updated. Our own convert() functions can also be used. Example
> usage of CONVERT():
>
> convert('PostgreSQL' using iso8859_1_to_utf8)
^^^^^
What is it? Is it really in standard? Sorry, but it seems
strange. What 'ISO8859-1' as name?
CAST( int_as_char ) ? :-)
.... CONVERT('PostgreSQL' USING 'ISO8859-1' TO 'UTF8')
Karel
--
Karel Zak <zakkr(at)zf(dot)jcu(dot)cz>
http://home.zf.jcu.cz/~zakkr/
C, PostgreSQL, PHP, WWW, http://docs.linux.cz, http://mape.jcu.cz
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | zakkr(at)zf(dot)jcu(dot)cz |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-06 08:19:50 |
Message-ID: | 20020806.171950.68052926.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> On Tue, Aug 06, 2002 at 02:55:04PM +0900, Tatsuo Ishii wrote:
> > I have added SQL99's CONVERT() function. docs and regression tests
> > also updated. Our own convert() functions can also be used. Example
> > usage of CONVERT():
> >
> > convert('PostgreSQL' using iso8859_1_to_utf8)
> ^^^^^
> What is it? Is it really in standard?
It's a "conversion name".
>From SQL99:
CONVERT <left paren> <character value expression>
USING <form-of-use conversion name> <right paren>
> Sorry, but it seems
> strange. What 'ISO8859-1' as name?
Sure, you can use '-' instead of '_' if you don't mind quoting it
with "(i.e. delimited identifier).
convert('PostgreSQL' using "iso8859-1-to-utf8")
I'm sure people don't like that way...
--
Tatsuo Ishii
From: | Karel Zak <zakkr(at)zf(dot)jcu(dot)cz> |
---|---|
To: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-06 08:49:59 |
Message-ID: | 20020806104958.B9339@zf.jcu.cz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
On Tue, Aug 06, 2002 at 05:19:50PM +0900, Tatsuo Ishii wrote:
> > On Tue, Aug 06, 2002 at 02:55:04PM +0900, Tatsuo Ishii wrote:
> > > I have added SQL99's CONVERT() function. docs and regression tests
> > > also updated. Our own convert() functions can also be used. Example
> > > usage of CONVERT():
> > >
> > > convert('PostgreSQL' using iso8859_1_to_utf8)
> > ^^^^^
> > What is it? Is it really in standard?
>
> It's a "conversion name".
>
> >From SQL99:
> CONVERT <left paren> <character value expression>
> USING <form-of-use conversion name> <right paren>
Ah.. conversion name. I was thinking it are names of encodings.
It's right.
Karel
--
Karel Zak <zakkr(at)zf(dot)jcu(dot)cz>
http://home.zf.jcu.cz/~zakkr/
C, PostgreSQL, PHP, WWW, http://docs.linux.cz, http://mape.jcu.cz
From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
Cc: | zakkr(at)zf(dot)jcu(dot)cz, <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-06 21:18:18 |
Message-ID: | Pine.LNX.4.44.0208062310280.927-100000@localhost.localdomain |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
Tatsuo Ishii writes:
> > Sorry, but it seems
> > strange. What 'ISO8859-1' as name?
>
> Sure, you can use '-' instead of '_' if you don't mind quoting it
> with "(i.e. delimited identifier).
>
> convert('PostgreSQL' using "iso8859-1-to-utf8")
>
> I'm sure people don't like that way...
I suggest using the official IANA names and replace all the non-identifier
characters by underscores and all upper-case letters with lower-case.
So it would be iso_8859_1_to_utf_8. That way it's almost as pretty but a
lot more predictable.
--
Peter Eisentraut peter_e(at)gmx(dot)net
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | peter_e(at)gmx(dot)net |
Cc: | zakkr(at)zf(dot)jcu(dot)cz, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-07 12:56:08 |
Message-ID: | 20020807.215608.115905307.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> I suggest using the official IANA names and replace all the non-identifier
> characters by underscores and all upper-case letters with lower-case.
> So it would be iso_8859_1_to_utf_8. That way it's almost as pretty but a
> lot more predictable.
Sounds reasonable. I'll look into this. However I have to examin each
encodings carefully. Because:
(1) some encodings are not listed IANA (e.g. TCVN, WIN874...)
(2) some offcial IANA names seem not appropriate
(e.g. Extended_UNIX_Code_Packed_Format_for_Japanese)
:
:
--
Tatsuo Ishii
From: | Kaori Inaba <i-kaori(at)sra(dot)co(dot)jp> |
---|---|
To: | pgsql-patches(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Cc: | t-ishii(at)sra(dot)co(dot)jp |
Subject: | Re: [HACKERS] SQL99 CONVERT() function |
Date: | 2002-08-13 07:00:58 |
Message-ID: | 20020813.160058.39162560.i-kaori@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
Hello,
The attached patch adds CONVERSION stuff for cyrillic and
win874/1250/1251/1256 encodings.
Thank you.
From: Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>
Subject: [HACKERS] SQL99 CONVERT() function
Date: Tue, 06 Aug 2002 14:55:04 +0900 (JST)
Message-ID: <20020806(dot)145504(dot)35027319(dot)t-ishii(at)sra(dot)co(dot)jp>
> I have added SQL99's CONVERT() function. docs and regression tests
> also updated. Our own convert() functions can also be used. Example
> usage of CONVERT():
>
> convert('PostgreSQL' using iso8859_1_to_utf8)
>
> will return 'PostgreSQL' in utf-8 encoding. See "String Functions and
> Operators" section of Users's guide for more details and currently
> available (predefined) conversions.
>
> I believe remaining work for CONVERSION stuffs is some conversions for
> cyrillic and win874/1250/1251/1256 encodings.
> --
> Tatsuo Ishii
-------------------
Kaori Inaba
i-kaori(at)sra(dot)co(dot)jp
Attachment | Content-Type | Size |
---|---|---|
pgsql.patch.gz | application/octet-stream | 13.6 KB |
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | i-kaori(at)sra(dot)co(dot)jp |
Cc: | pgsql-patches(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] SQL99 CONVERT() function |
Date: | 2002-08-13 07:06:05 |
Message-ID: | 20020813.160605.110114918.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> The attached patch adds CONVERSION stuff for cyrillic and
> win874/1250/1251/1256 encodings.
Thanks. I'll take care of this.
--
Tatsuo Ishii
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | i-kaori(at)sra(dot)co(dot)jp |
Cc: | pgsql-patches(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] SQL99 CONVERT() function |
Date: | 2002-08-14 02:52:24 |
Message-ID: | 20020814.115224.51704194.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> > The attached patch adds CONVERSION stuff for cyrillic and
> > win874/1250/1251/1256 encodings.
>
> Thanks. I'll take care of this.
Done. Documents and regression tests have been updated also. I think
now we have implemented all encoding conversions for 7.3 release.
--
Tatsuo Ishii
From: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
---|---|
To: | peter_e(at)gmx(dot)net |
Cc: | zakkr(at)zf(dot)jcu(dot)cz, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-14 05:31:12 |
Message-ID: | 20020814.143112.112622202.t-ishii@sra.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
> > I suggest using the official IANA names and replace all the non-identifier
> > characters by underscores and all upper-case letters with lower-case.
> > So it would be iso_8859_1_to_utf_8. That way it's almost as pretty but a
> > lot more predictable.
>
> Sounds reasonable. I'll look into this. However I have to examin each
> encodings carefully. Because:
>
> (1) some encodings are not listed IANA (e.g. TCVN, WIN874...)
>
> (2) some offcial IANA names seem not appropriate
> (e.g. Extended_UNIX_Code_Packed_Format_for_Japanese)
> :
> :
Done. See current doc (user's guide "6.4. String Functions and
Operators" Table 6-7 "Available conversion names") how I changed the
conversion names.
--
Tatsuo Ishii
From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp> |
Cc: | zakkr(at)zf(dot)jcu(dot)cz, <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: SQL99 CONVERT() function |
Date: | 2002-08-20 21:22:45 |
Message-ID: | Pine.LNX.4.44.0208202317590.989-100000@localhost.localdomain |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-hackers pgsql-patches |
Tatsuo Ishii writes:
> Done. See current doc (user's guide "6.4. String Functions and
> Operators" Table 6-7 "Available conversion names") how I changed the
> conversion names.
What guideline did you follow? For example, should koi8r be koi8_r? Or
should winXXX be win_XXX?
--
Peter Eisentraut peter_e(at)gmx(dot)net