MySQL function?

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Mike Starke
Date:  
Subject: MySQL function?
On Mon, Sep 22, 2003 at 01:56:49PM -0700, Derek Neighbors wrote:
/_Matt Alexander said:
/_> Mike Starke said:
/_>>
/_>> Is there a function in MySQL similar to that in Excel's "proper()"?
/_>>
/_>> For instance, I would like to do a select on a column that has
/_>> all CAPS and display the query in proper case (Mike versus MIKE).
/_>
/_> select concat(ucase(left(first_name,1)),lcase(SUBSTRING(first_name,2)))
/_> as First_Name from myTable;
/_
/_This falls down if my first name is MARY ANN or LAURIE JEAN, etc...
/_
/_As stated you could handle programmatically (someone gave a suggestion if
/_the language used to retrieve the data was php) or utter bastardazation of
/_string functions in mysql.

Aw, Matt was just trying to help...bastardazation, maybe,
but utter bastadazation, nah. :-)

The queries I run are normally on the command line with logging
done via \T. PHP wouldn't help much here unless I changed my habits.

tanks,

-mike