+ Reply to Thread
Results 1 to 4 of 4

Formula to extract parts of text string

  1. #1
    Registered User
    Join Date
    09-07-2012
    Location
    Philadelphia
    MS-Off Ver
    Excel 2010
    Posts
    12

    Formula to extract parts of text string

    From the example below, how can I write a formula so that I can extract just the name and have it read: Evan Dorris. I'm able to get Dorris with a left/find formula but can't get the first name - more so, I would need it First, Last name. All of the data sets I am working with have this same format so any help is appreciated....thanks!

    "Dorris/Evan T-Ticket Related Serv"

  2. #2
    Valued Forum Contributor
    Join Date
    01-19-2012
    Location
    Barrington, IL
    MS-Off Ver
    Excel 2007/2010
    Posts
    1,211

    Re: Formula to extract parts of text string

    Are all names in a "Lastname/Firstname" format?

    You can use a MID/FIND to get the first name.

    So...

    =TRIM(MID(C1,FIND("/",C1)+1,FIND(" ",C1)-FIND("/",C1)))

    Assuming there is a SPACE after the first name name
    Last edited by Speshul; 09-11-2014 at 09:51 AM.
    You should hit F5, because chances are I've edited this post at least 5 times.
    Example of Array Formulas
    Quote Originally Posted by Jacc View Post
    Sorry, your description makes no sense. I just made some formula that looks interesting cause I had nothing else to do.
    Click the * below on any post that helped you.

  3. #3
    Registered User
    Join Date
    09-07-2012
    Location
    Philadelphia
    MS-Off Ver
    Excel 2010
    Posts
    12

    Re: Formula to extract parts of text string

    Awesome - huge help. Thank you!

  4. #4
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Formula to extract parts of text string

    Or just use one formula to get the name

    =TRIM(RIGHT(SUBSTITUTE(LEFT(A1,FIND(" ",A1)),"/",REPT(" ",255)),255))&" "&LEFT(A1,FIND("/",A1)-1)

    A
    B
    1
    Dorris/Evan T-Ticket Related Serv Evan Dorris
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  5. #5
    Registered User
    Join Date
    09-07-2012
    Location
    Philadelphia
    MS-Off Ver
    Excel 2010
    Posts
    12

    Re: Formula to extract parts of text string

    Many thanks - extremely helpful. As I'm working through the data, I actually see that instead of a space after Dorris/Evan, there are instances where it might be Dorris/Evan-

    Is there a way to include in the same formula something to differentiate whether or not there is a " " or "-" after Dorris/Evan to produce the same result?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Extract text from a string of text (amend formula to include new criteria)
    By robertguy in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-10-2013, 04:53 PM
  2. formula to extract a section of of a text string
    By dcgrove in forum Excel General
    Replies: 6
    Last Post: 07-02-2010, 11:28 AM
  3. Extract certain parts of string
    By djDaemon in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-02-2006, 03:45 PM
  4. [SOLVED] RE: Extract certain parts of string
    By djDaemon in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 02-02-2006, 11:35 AM
  5. Formula to extract digits from a text string?
    By Hash@example.org in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 01-15-2006, 12:16 AM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1