+ Reply to Thread
Results 1 to 7 of 7

Formula to extract 3rd string starting from right

  1. #1
    Registered User
    Join Date
    11-29-2011
    Location
    Manila, Philippines
    MS-Off Ver
    Excel 2003
    Posts
    41

    Formula to extract 3rd string starting from right

    Hello!
    Need help on how to extract the 3rd string starting from right separated by commas.
    And also the formula to extract the remaining string starting from left. Kindly check attached.
    Thank you!!!
    Attached Files Attached Files

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Formula to extract 3rd string starting from right

    try this for column C... =MID(A2,LEN(A2)-4,1)
    still playing around with col D.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Formula to extract 3rd string starting from right

    try this for column D... =IFERROR(LEFT(A2,LEN(A2)-6),"")

  4. #4
    Valued Forum Contributor
    Join Date
    10-29-2012
    Location
    Mojokerto,Indonesia
    MS-Off Ver
    Excel 2007
    Posts
    554

    Re: Formula to extract 3rd string starting from right

    at B2
    =LEFT(TRIM(RIGHT(SUBSTITUTE($A2,",",REPT(" ",LEN($A2))),2*LEN($A2))))

    at C2
    =LEFT(TRIM(RIGHT(SUBSTITUTE($A2,",",REPT(" ",LEN($A2))),3*LEN($A2))))

    at D2
    =IFERROR(LEFT($A2,LEN($A2)-6),"")

    copy down

  5. #5
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Formula to extract 3rd string starting from right

    I didn't work on the formula in col B because you had a formula there but if you want that and like Ghozi's formula you can change the one in B2 to this...
    =LEFT(TRIM(RIGHT(SUBSTITUTE($A2,",",REPT(" ",LEN($A2))),COLUMN(B$1)*LEN($A2))))
    and drag toward the right and it will give you the results you want in col C too.

  6. #6
    Registered User
    Join Date
    11-29-2011
    Location
    Manila, Philippines
    MS-Off Ver
    Excel 2003
    Posts
    41

    Re: Formula to extract 3rd string starting from right

    Thanks Sambo! sorry.. for the string value its not always 1 character string e.g.
    AA,BB,CC
    A,BBB,CCC
    AAA,B,CCCCC
    Last edited by spishowtime; 03-31-2020 at 09:45 PM.

  7. #7
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,554

    Re: Formula to extract 3rd string starting from right

    For column C try: =TRIM(LEFT(RIGHT(SUBSTITUTE(A2,",",REPT(" ",100)),300),100))
    For column D try: =IFERROR(LEFT(A2,SEARCH(C2,A2)-2),"")
    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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] Formula to search a range for a string and then extract certain dta from string
    By gratedane8 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-08-2018, 06:09 PM
  2. [SOLVED] formula to find starting position and count numbers in a string
    By craig04 in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 04-07-2017, 03:33 PM
  3. [SOLVED] Formula to extract number from a string
    By Bobbbo in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-28-2017, 03:04 AM
  4. Help with an extract string formula
    By SEMMatt in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 03-18-2015, 03:20 PM
  5. [SOLVED] MID formula to string extract
    By nur2544 in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 06-09-2014, 02:01 PM
  6. Using Find or Search to extract data starting point from a formula
    By mike_vr in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 04-08-2014, 12:31 PM
  7. [SOLVED] Looking for a formula to extract a tax id from a string
    By lychee in forum Excel General
    Replies: 13
    Last Post: 12-04-2013, 04:20 PM

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