Peter,
I would treat each as a list and loop over each "memo" field within the loop
creating the full name for inserting into the DB...
<cfset NumberIterations = ListLen(form.firstname, ",")>
<CFLOOP FROM="1" TO="#numberIterations#" index="i">
<CFSET fullname = "" & ListGetAt(form.firstname, #i#, ",") & " " &
ListGetAt(form.middlename, #i#, ",") & " " &
ListGetAt(form.lastname, #i#, ",") & "">
<insert fullname into db with other info...>
</CFLOOP>
This will break badly if any of the fields are blank!
But on another note, why do you have it this way to begin with???
HTH.
Jeff Garza
Lead Developer/Webmaster
Spectrum Astro, Inc.
[EMAIL PROTECTED]
-----Original Message-----
From: Peter Tilbrook
To: CF-Talk
Sent: 6/5/01 6:20 PM
Subject: List question
I have three "memo" database fields delimited by commas:
1. FirstName (eg: John,Michael,James)
2. MiddleName (eg: Pat,Tony,Peter)
3. LastName (eg: Smith,Affleck,Cousins)
So the three names should come out as:
John Pat Smith
Michael Tony Affleck
James Peter Cousins
How can I extract these and wrap them up into a single variable? (so I
can
insert each name into a form as a seperate record).
Thanks!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists