MySQL Forums
Forum List  »  InnoDB

Re: help merge information
Posted by: Ryan Lowe
Date: November 19, 2008 02:37PM

The following query will re-format the "last, first" into "first last":

select concat(substr(name,instr(name,',')+2), ' ', substr(name,1,instr(name,',')-1)) as formatted_name from t1;

Hope that helped.

-- Ryan Lowe

Options: ReplyQuote


Subject
Views
Written By
Posted
2992
November 17, 2008 12:24AM
2301
November 18, 2008 10:16AM
2207
November 19, 2008 01:39PM
Re: help merge information
2168
November 19, 2008 02:37PM
2185
November 20, 2008 06:53PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.