logo       

RE: How do I load extended (accented) ascii characters from text files?: msg#00132

db.mysql.windows

Subject: RE: How do I load extended (accented) ascii characters from text files?

Thanks for that reply, that will help when I start coding the webpage. But
at the moment I am trying to load a text file of data taken out of MS ACCESS
into MySQL running on my WIN 2000 system, and it is not handling the
extended characters properly. Is there a way to get my WINDOWS system to
handle these characters properly when I bulk load this text file?

thanks,
Bob Bruce

-----Original Message-----
From: Petr Vileta [mailto:petr@xxxxxxxxxxxxx]
Sent: February 20, 2003 9:41 AM
To: win32@xxxxxxxxxxxxxxx
Subject: Re: How do I load extended (accented) ascii characters from
text files?


> Whenever I try to enter data into text fields using either the load
> statement on an ascii file or an insert statement that has extended ascii
> (accented) characters in the range of 128 to 154 and then try to examine
the
> data stored in MySQL I get gobbledegook characters. When I enter this same
> data from within the MySQL command line interface (in Windows 2K) the data
> displays correctly.
>
>
> I am quite concerned about this because I am starting to build a PHP
> application
> that will take input from HTML forms and put them into the database using
> INSERT statements and I don't want to have this happen there.

I meant that problem is in different codepages in html page and operating
system. Windows use win1252 charset for western languages or win1252 for
east-europe languages.
You must put
<META HTTP-EQUIV="Content-type" CONTENT="text/html; CHARSET=windows-1252">
or
<META HTTP-EQUIV="Content-type" CONTENT="text/html; CHARSET=iso-8859-1">
or
<META HTTP-EQUIV="Content-type" CONTENT="text/html; CHARSET=iso-8859-2">
between <head> and </head> into your html pages. If you put windows-1252
into html pages it should be OK I hope. If you put iso-8852-1 or -2, you
must write some translating subroutine in php script and to translate
received data before you store data to database.

Petr Vileta, Czech Republic
http://www.practisoft.cz




---------------------------------------------------------------------
Please check "http://www.mysql.com/Manual_chapter/manual_toc.html"; before
posting. To request this thread, e-mail win32-thread10601@xxxxxxxxxxxxxxx

To unsubscribe, send a message to the address shown in the
List-Unsubscribe header of this message. If you cannot see it,
e-mail win32-unsubscribe@xxxxxxxxxxxxxxx instead.




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise