On Tue, Dec 1, 2009 at 12:20 PM, Anthony <[email protected]> wrote:
> On Tue, Dec 1, 2009 at 12:17 PM, Marcus Wolschon
> <[email protected]> wrote:
>> How is that a problem for MySQL?
>> "h" and "H" have different binary representations and are
>> thus different keys, are they now?
>
> By default MySQL treats all comparisons on varchars as case insensitive.

mysql> create table blah ( `k` varchar(255) NOT NULL default '',
primary key (k));
Query OK, 0 rows affected (0.00 sec)

mysql> insert into blah values ('hellO');
         Query OK, 1 row affected (0.00 sec)

mysql> select * from blah where k='hello';
+-------+
| k     |
+-------+
| hellO |
+-------+
1 row in set (0.02 sec)

The exception would be if your default collation is binary (which
would have the same side-effect as to making your sorts bunch all the
capital letters together and all the lowercase letters together).

If you need to sort 'H' next to 'h', but don't want to treat 'H' as
equal to 'h', you need to use a database other than MySQL.

_______________________________________________
osmosis-dev mailing list
[email protected]
http://lists.openstreetmap.org/listinfo/osmosis-dev

Reply via email to