Re: Parsing data for insert from one table to another

From: Jim Kennedy <kennedy-family_at_home.com>
Date: Tue, 06 Nov 2001 01:59:20 GMT
Message-ID: <YtHF7.24243$Tb.13152218_at_news1.sttln1.wa.home.com>


Its not easy. There are exceptions.
Do all names have a suffix? Are all last names without spaces? (probably not e.g. Mc Connell etc.) So on the last name it might be difficult. Then on the first name are all first names without a space?

You first need to define the rules on how you are going to seperate the name into pieces then you can write a query to do so. Please post the rules first.

Jim
"Chris" <chris_self_at_yahoo.com> wrote in message news:52f2f187.0111051202.6b75aeee_at_posting.google.com...
> Hi all -
>
> I would like to select a name field from one table (TableA) in the format:
>
> Smith Jr., John Paul
>
> and extract each piece to insert into fields on TableB
>
> First_Name
> Middle_Name
> Last_Name
> Suffix
>
> Does anyone know how I can do this with SQL?
>
> Thanks in advance.
Received on Tue Nov 06 2001 - 02:59:20 CET

Original text of this message