From: Dereck L. Dietz <>
Date: Thu, 26 Mar 2009 16:45:32 -0400
Message-ID: <GNRyl.15036$>

Windows 2003 Server

I have a query which was designed using a regular expression to get the LAST and FIRST name from a column which had one string in the format of LAST, FIRST MI/NAME in one column. It originally worked written as:

last_name = regexp_replace(name, '(.+), (.+) (.+)','\1') first_name =regexp_replace(name, '(.+), (.+) (.+)','\2')

But now the data we receive has been changed and there are now rows in the data with only a LAST and FIRST names.

I'm not very familiar with regular expressions so can anybody either show me how or point me to an example of where I could possibly handle both possibilities?

Thanks very much. Received on Thu Mar 26 2009 - 15:45:32 CDT

Original text of this message