logo       

Re: Case Insensitivity of queries and record lookup: msg#01112

db.mysql.general

Subject: Re: Case Insensitivity of queries and record lookup

At 14:27 -0400 6/28/02, Mark Hennessy wrote:
I have noticed after migrating my database from mSQL to MySQL that queries
are providing lookup results in a case-insensitive manner.

An example (in mSQL):

SELECT * FROM custiebase WHERE my_id = "FOO001"\g
would return the record for FOO001.

SELECT * FROM custiebase WHERE my_id = "foo001"\g
would return that the record couldn't be found

Same example (in MySQL):

SELECT * FROM custiebase WHERE my_id = "FOO001";
would return the record for FOO001.

SELECT * FROM custiebase WHERE my_id = "foo001";
would return the record for FOO001.

=

Why is this? Is there a way that I can return to the case-sensitive
behavior that had existed with my mSQL db with MySQL?

If your columns are CHAR or VARCHAR, convert them to CHAR BINARY
or VARCHAR BINARY. If they are TEXT, convert them to BLOB.


--
Mark P. Hennessy mark@xxxxxxxxxx


---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <mysql-thread113361@xxxxxxxxxxxxxxx>
To unsubscribe, e-mail
<mysql-unsubscribe-gcdmg-mysql=m.gmane.org@xxxxxxxxxxxxxxx>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




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

News | FAQ | advertise