[dba-VB] Splitting a name

jwcolby jwcolby at colbyconsulting.com
Sat Apr 19 11:08:13 CDT 2008


I have a table with eight million records, with a single name field, and 
I have a library that splits the name into components.  What I need now 
is a generic method of getting the name out of a table and updating a 
specific set of fields back in the table.  It has to do so QUICKLY since 
I have to update 80 million names.

In this case I have a single table

Name

NamePrefix
LastName
FirstName
MiddleName
NameSuffix

Name already exists and contains a name in a consistent format LName 
FName MName.

The other fields I have added to my table.

So what I am looking for is a general strategy.  I assume I will open a 
read recordset with the PKID and the name field, then iterate through 
this recordset performing the split.

Once I do that should I:

Build a dynamic SQL Update query and execute that?

Build a stored procedure that I pass the PKID and the name parts to 
which then updates the data?

Use an ADO recordset to do this?

some other method entirely?

I am assuming at this point that because of the sheer size of the data I 
do not want to try and do this in an ado recordset.  Eight million 
records sitting in data at one time does not sound fun.

All ideas gratefully accepted.

-- 
John W. Colby
www.ColbyConsulting.com



More information about the dba-VB mailing list