write a SQL function, say fnFirstName(varchar firstname), which looks for
first space in the Name field.
Similiarly other functions for MiddleName and LastName. Use those functions
in the SQL select statement to separate the data as individual field
names..
Does it sound better?
Anna Leon
<[EMAIL PROTECTED]
om> To
[EMAIL PROTECTED]
12/09/2004 07:15 om
AM cc
Subject
Please respond to RE: [AspNetAnyQuestionIsOk]
AspNetAnyQuestion Breaking apart fields
[EMAIL PROTECTED]
com
Yes I know that, but I converted a database from
Access to SQL so the Name column consisted of First
Name, Middle Initial, and Last Name already.
Hence, I would like to break that column apart and do
whatever.
--- Peter Brunone <[EMAIL PROTECTED]> wrote:
>
> Simple answer: If you have three pieces of data,
> then you have
> three fields on the form.
>
> You could split based on spaces, but if you have a
> first name
> like "Mary Ann" or a last name like "Van Zandt",
> that just won't work.
>
> -----Original Message-----
> From: sas0riza [mailto:[EMAIL PROTECTED]
>
> This is a more SQL question, but how do you break
> apart a field? For
> instance, in a column, I have both first name,
> middle initial,
> and last name. (e.g. Mary J. Smith). How do I write
> the SQL so that
> it'll break apart the different parts of the name
> and then insert it
> into it's appropriate column?
>
> Mary -> FirstName
> J -> MiddleInitial
> Smith -> LastName
>
> Any help is appreciated!
>
> Thanks!
>
>
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
Yahoo! Groups Links
Disclaimer:
The contents of this e-mail are strictly confidential and may be
privileged. It represents solely the views of the author and is meant only
for the stated recipient/s.
Any unauthorized distribution is strictly prohibited. F J Benjamin Group
or its subsidiaries will not accept responsibility for any damage caused by
this e-mail or
attachment/s (if any), which have been checked for viruses.
Please visit our website http://www.fjbenjamin.com
------------------------ Yahoo! Groups Sponsor --------------------~-->
$4.98 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/Q7_YsB/neXJAA/yQLSAA/saFolB/TM
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/