+ Reply to Thread
Results 1 to 15 of 15

Separating digit of numbers into each cell?

  1. #1
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Separating digit of numbers into each cell?

    Separating

    Hello everyone, as you can see in the picture;

    it is possible to separate numbers from Column A into each column of B and C?

  2. #2
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Separating digit of numbers into each cell?

    In B1 this: =LEFT(A1,3)
    In C1 this: =RIGHT(A1,3)
    and drag them down

    If you want the results to be numeric just add *1 to each formula

  3. #3
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    Quote Originally Posted by cutter View Post
    in b1 this: =left(a1,3)
    in c1 this: =right(a1,3)
    and drag them down

    if you want the results to be numeric just add *1 to each formula
    dang! Thanks again cutter !

  4. #4
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    WAIT! what if I have 72-120 in A1, also what if I have 1-2 in A1?

    I don't want the dash sign include it.

  5. #5
    Forum Guru
    Join Date
    05-24-2011
    Location
    India
    MS-Off Ver
    Office 2021
    Posts
    2,237

    Re: Separating digit of numbers into each cell?

    B1,

    =left(a1,find("-",a1)-1)

    c1,

    =mid(a1,find("-",a1)+1,250)
    Regards,
    Haseeb Avarakkan

    __________________________________
    "Feedback is the breakfast of champions"

  6. #6
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Separating digit of numbers into each cell?

    I figured that would be the next question.

    so now it would be:
    In B1: =LEFT(A1,FIND("-",A1)-1)
    and if the length after the "-" is variable then
    In C1: =RIGHT(A1,LEN(A1)-FIND("-",A1))

  7. #7
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    Quote Originally Posted by Cutter View Post
    I figured that would be the next question.

    so now it would be:
    In B1: =LEFT(A1,FIND("-",A1)-1)
    and if the length after the "-" is variable then
    In C1: =RIGHT(A1,LEN(A1)-FIND("-",A1))
    LMAO, you must be for FORTUNE TELLER!

    Hey sorry man but the formula didn't work well like this formula Haseeb gave it to me.

    B1,

    =left(a1,find("-",a1)-1)

    c1,

    =mid(a1,find("-",a1)+1,250)

    here is my data..


    187-474
    135-337
    96-206
    90-199
    77-217
    68-109
    39-110
    33-102
    22-58
    24-61
    14-48
    20-51
    3-19
    2-17
    188-438
    163-375

  8. #8
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    thank you Haseeb and Cutter, you are great thank you for helping me.

  9. #9
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Separating digit of numbers into each cell?

    Why not just use Text to Colums on data that looks like what you posted?

    Use the - as the delimiter

    Nevermind: I just read where you want the results in B and C.
    HTH
    Regards, Jeff

  10. #10
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    Quote Originally Posted by jeffreybrown View Post
    Why not just use Text to Colums on data that looks like what you posted?

    Use the - as the delimiter
    how you use text to columns?

  11. #11
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    ok never mind, i figure it out...
    i'm so exxcel noob LOL!

    thank you EVERYONE!!!!!!!!!!!!!!!

  12. #12
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Separating digit of numbers into each cell?

    Highlight the column (column A) >> Data Tab >> Text to Columns >> Delimited >> Next >> Other (in the box place a -) >> Finish

    Results from column A will now be split between A and B

  13. #13
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    Got it , thanks jeffrey

  14. #14
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Separating digit of numbers into each cell?

    There's also this for C1

    =SUBSTITUTE(A1,LEFT(A1,FIND("-",A1)),"")

  15. #15
    Forum Contributor
    Join Date
    04-30-2012
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2007
    Posts
    234

    Re: Separating digit of numbers into each cell?

    Quote Originally Posted by Cutter View Post
    There's also this for C1

    =SUBSTITUTE(A1,LEFT(A1,FIND("-",A1)),"")
    hey both your function work. thank you cutter!

    =LEFT(A1,FIND("-",A1)-1)

    &

    =SUBSTITUTE(A1,LEFT(A1,FIND("-",A1)),"")

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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