Results 1 to 2 of 2

Thread: Parsing data

  1. #1
    Join Date
    Jan 2009
    Posts
    124

    Unanswered: Parsing data

    I have a number of names & email addresses being entered in one field in a form. I want to create a separate record for each set. Is there a way in SQL to do this or does this need to happen on PHP?

    e.g. "Jxxx Jxxxx" <jxxx@yahoo.com>, "Nyyy Jyyyy" <yyy@yyy.com>, "Nzzz Jzzz" <zzz@zzz.org>, "Wwww Awww" <www@www.com>

    into a table like:

    _____________________
    id |name | email
    _____________________
    1 |Jxxx Jxxxx |<jxxx@yahoo.com>
    _____________________
    2 |Nyyy Jyyyy|<yyy@yyy.com>

    Nick

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    much easier if you do it with php -- the sql solution is quite messy
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •