Tuesday, April 28, 2009

Converting Letter Case in php/MySql


LCASE can be used in MySQL query to get the output in all lower case letters.

For example below query will display the username in lowercase.

SELECT lcase(username) FROM `users`

Similarly UCASE can be used for getting the output in all upper case letters.

Alternatively, we can use php functions strtolower() and strtoupper() for achieving the samething.
More Articles...

No comments:

Search This Blog