Search Postgresql Archives

Re: pgsql cannot read utf8 files moved from windows correctly!

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

 



On 12/20/07, Martijn van Oosterhout <kleptog@xxxxxxxxx> wrote:
> On Tue, Dec 18, 2007 at 02:53:16PM +0800, bookman bookman wrote:

> > I know that every line of utf8 files  is started with "fffe" or "feff"
> >  and ended with "\r\n" in windows but not in linux,so  the character
> > "1" has a space before it in the error line.

> Err, no. In UTF-16 files it is common to begin the *file* with that
> character, but UTF-8 doesn't have that character anywhere, it's
> illegal. Just stripping them out should be fine.

A BOM is perfectly legal in UTF-8, and it's commonly used as a
signature to indicate the text is UTF-8 instead of another encoding.
But yes, it is at the beginning of the file only.

http://unicode.org/faq/utf_bom.html#29

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

               http://archives.postgresql.org/

[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