DynDeveloper.com

DynDeveloper.com

Sign Up Now!Log In
sgray128 11/13/2012 9:03:37 AM

Parsing a field in SQL server

A long time friend send me a request to parse the first name and last name from the dataset that you see below. I'm going to post the answer that I sent, but it was kind of fun so I thought I'd post it as an exersize and to see if anyone else had a better solution. Points for any answer better than mine.  

declare @iv30102 table (itemdesc varchar(100))
insert into @iv30102 (itemdesc) values ('01/01/2010 Smith, Gabriella     WHOLESALE')
insert into @iv30102 (itemdesc) values ('01/04/2010 Farnsworth,Joe     WHOLESALE')
Version: GP 2010
Section: SQL Scripts