Question: I'd like to be able to do queries that normalize accented characters, so that for example:

```
é, è, and ê

```

are all treated as 'e', in queries using '=' and 'like'. I have a row with username field set to '**rené**', and I'd like to be able to match on it with both '**rene**' and '**rené**'.

I'm attempting to do this with the 'collate' clause in MySQL 5.0.8. I get the following error:

```
mysql> select * from User where username = 'rené' collate utf8_general_ci;
ERROR 1253 (42000): COLLATION 'utf8_general_ci' is not valid for CHARACTER SET 'latin1'

```

FWIW, my table was created with:

```
CREATE TABLE `User` (
  `id` bigint(19) NOT NULL auto_increment,
  `username` varchar(32) NOT NULL,
  PRIMARY KEY  (`id`),
  UNIQUE KEY `uniqueUsername` (`username`)
) ENGINE=InnoDB AUTO_INCREMENT=56790 DEFAULT CHARSET=utf8

```

Answer: 
I have implemented a strtr php function/tr unix command in MySQL you can get the source [here](https://github.com/falcacibar/mysql-routines-collection/blob/master/tr.func.sql)

You can use as:

```
SELECT tr(name, 'áäèëî', 'aaeei') FROM persons

```

or to strip some characters

```
SELECT tr(name, 'áäèëî', null) FROM persons

```
```
$normalized = iconv('UTF-8', 'ASCII//TRANSLIT', $string);

```

is a perfect php solution, but in mysql? CONVERT?

in mysql

```
SELECT 'Álvaro José' as accented, (CONVERT ('Álvaro José' USING ascii)) as notaccented

```

Produce:

```
Álvaro José     ?lvaro Jos?

```

The accented words is not converted to no accented words, it is not equivalent a translit of iconv.

RegExp don't work with UTF-8.

Not any solution.