Re: MYSQL doesn't 'see' accents
Posted by: Evi Wool
Date: June 26, 2010 03:34PM

Hi Peter, I've done some searches in Google so I'm guessing that you mean
Did I give any extra commands when I signed on.
Well I signed on with
Set Names 'utf8';
I then typed in
show variables like "%character%";
which got the results as follows:

| Variable_name | Value |
+--------------------------+----------------
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | latin1 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | latin1 |
| character_set_system | utf8 |

Since only one column in the database would contain accents (ironically, the one that contained English words), I modified that column to UTF8

SHOW CREATE TABLE TblEngTest;
and got this enlightening result:
| tblengtest | CREATE TABLE `tblengtest` (
`EngID` int(10) NOT NULL AUTO_INCREMENT,
`English` varchar(255) CHARACTER SET utf8 DEFAULT NULL,
PRIMARY KEY (`EngID`),
UNIQUE KEY `English` (`English`)
) ENGINE=MyISAM AUTO_INCREMENT=37711 DEFAULT CHARSET=latin1 |

I also tried signing in using 2 lines after the usual
cd \mysql\bin
mysql -u root

that is
Set names 'utf8';
set character set utf8;
but the second line seemed to undo the first one somehow and
SHOW VARIABLES indicated that the
character_set_connection was now back to Latin1

I suspect, after all that, the answer is that the database needed to have been created with UTF8.
I've got a horrible problem that while this will (or possibly only MAY) solve one problem, it may create others but I'm not sure about that. If that is so, I'd be better finding the problem rows in Access and then editing manually.

Options: ReplyQuote


Subject
Views
Written By
Posted
4361
June 23, 2010 05:31PM
1801
June 23, 2010 09:34PM
1926
June 24, 2010 12:00AM
2057
June 24, 2010 03:14AM
1862
June 24, 2010 05:59AM
1937
June 24, 2010 04:09PM
2640
June 26, 2010 06:12AM
1981
June 26, 2010 12:04PM
Re: MYSQL doesn't 'see' accents
2076
June 26, 2010 03:34PM
3802
June 26, 2010 06:46PM
1964
June 27, 2010 02:09AM
1937
June 27, 2010 12:48PM
2317
June 27, 2010 11:50PM
1822
June 28, 2010 12:13AM
1914
June 28, 2010 07:59PM
1773
June 28, 2010 09:27PM
2310
June 30, 2010 01:29AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.