List:General Discussion« Previous MessageNext Message »
From:Bernhard Doebler Date:August 3 2001 11:33am
Subject:Re: MySQL and CharSets
View as plain text  
----- Original Message ----- 
From: "Werner Stuerenburg" <ws@stripped>
To: "Bernhard Doebler" <programmer@stripped>
Cc: <mysql@stripped>
Sent: Friday, August 03, 2001 10:45 AM
Subject: Re: MySQL and CharSets


> 
> 
> Bernhard Doebler schrieb am Freitag, 3. August 2001, 08:40:35:
> 
> > I import a CSV file into MySQL using LOAD DATA INFILE. That's no problem. The
> problem is the textfile contains German umlauts. When I query the table with MySQL-program
> on the console (SQL monitor)
> > it even works fine.
> > But when I output in PHP it only shows the correct characters if I send header 
> > header("Content-type: text/html; charset=IBM850");
> > I don't want to use charset IBM850 but ISO-8859-1. How to convert the umlauts.
> Why are they different in both charsets?
> 
> 
> So play save, you would not like to depend on character sets at
> all.  I don't deal directly with output, send anything through a
> function instead.  This function simply converts all non-seven
> bit characters to HTML entities.  Remember, HTML was intended to
> produce the same output regardless of the system used.
> 
> There is a function in php proper, but for some reason I don't
> remember I decided to write my own.  Just look for string
> functions in php and you'll be fine.
> 

Hallo Werner;

the problem is I don't generate the CSV file. I simply import it in MySQL. I'd love to
import it as ISO-8859-1 but I didn't find a way.

Grüße (Best regards)
Bernhard Doebler

Thread
MySQL and CharSetsBernhard Doebler3 Aug
  • Re: MySQL and CharSetsWerner Stuerenburg3 Aug
  • Re: MySQL and CharSetsBernhard Doebler3 Aug
  • Re: MySQL and CharSetsGrigory Bakunov4 Aug