In attached at C2, I want to extract data from A:A, between Beginning and "-" with criteria : all which contain "/" , in consecutive order
In attached at C2, I want to extract data from A:A, between Beginning and "-" with criteria : all which contain "/" , in consecutive order
Is it correct?
A B C 1 Name Name 2Text2 AK123/007 3AK123/007-Text3 12345/001 412345/001-Text4 114477/135 5114477/135-Text5 2345/033 6Text6 72345/033-Text6
I am sure that it can be solved easier but it works (if you got lost of rows with data, I suggest to consider some vba UDF).
A B C 1 Name Name 2Text2 =IFERROR(TRIM(LEFT(INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW()-1)),FIND("-",INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW()-1)))-1)),"")
Formula in C2 is array type so it have to be accept with Shift+Ctrl+Enter (not just Enter as usual).
Happy with my answer * Add Reputation.
If You are happy with solution, please use Thread tools and mark thread as SOLVED.
yes, but with no TRIM, and I got it !
Thanks !
Last edited by ionelz; 03-25-2020 at 11:53 AM.
=IFERROR(LEFT(INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW()-1)),FIND("-",INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW()-1)))-1),"")
Trim removed
HTH
Regards, Jeff
Just to avoid leading spaces. Removed it if leading spaces are important.
Works, Thank you
You are very welcome. We are happy to help and thanks for the feedback.
If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.
Also, as a relatively new member of the forum, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.
If I move start location
A from A1 to A5 down
C from C2 to C4, how formula would change ?
not sure where to change rows
Last edited by ionelz; 03-25-2020 at 01:02 PM.
Try
=IFERROR(LEFT(INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW())),FIND("-",INDEX($A:$A,SMALL(IF(IFERROR(FIND("/",$A$2:$A$7),0),ROW($A$2:$A$7),10^10),ROW())))-1),"")
Hi ionelz,
Please stop updating your post after you've been given an answer. This is twice now and every time my answer had to be updated to correct what you changed.
Please think about what you want and then post an updated workbook with a clear before and after and your actual setup.
All good ! Your answer is correct and I will keep that !
I did not expect such an fast answer, that why I updated !
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks