1. #1
    Formulawiz
    Formulawiz's Avatar Become A Pro!
    Join Date: 01-12-09
    Posts: 1,589

    Excel question

    Have pitcher name
    T STAUFFER-R
    T STAUFFER-L

    Want to get rid of "-R" or "-L" in a cell and just capture the Name
    When pitchers change you dont know if it will end with the L or R

  2. #2
    FourLengthsClear
    King of the Idiots
    FourLengthsClear's Avatar Become A Pro!
    Join Date: 12-29-10
    Posts: 3,808
    Betpoints: 508

    If your pitcher name is in cell A1 then

    =SUBSTITUTE(A1,RIGHT(A1,2),"")

  3. #3
    Formulawiz
    Formulawiz's Avatar Become A Pro!
    Join Date: 01-12-09
    Posts: 1,589

    Quote Originally Posted by FourLengthsClear View Post
    If your pitcher name is in cell A1 then

    =SUBSTITUTE(A1,RIGHT(A1,2),"")

    Does not work. I have a name such as T WOOD-L.
    Your formula does not get rid of the "-L"

  4. #4
    FourLengthsClear
    King of the Idiots
    FourLengthsClear's Avatar Become A Pro!
    Join Date: 12-29-10
    Posts: 3,808
    Betpoints: 508

    Quote Originally Posted by Formulawiz View Post
    Does not work. I have a name such as T WOOD-L.
    Your formula does not get rid of the "-L"
    It works fine for me, are you sure you entered it correctly?


  5. #5
    goucla
    goucla's Avatar SBR PRO
    Join Date: 09-11-10
    Posts: 1,262
    Betpoints: 558

    r u using this to determin just win % against opp or is this a more complicated system?

  6. #6
    WendysRox
    WendysRox's Avatar Become A Pro!
    Join Date: 07-22-10
    Posts: 184
    Betpoints: 37

    Quote Originally Posted by FourLengthsClear View Post
    If your pitcher name is in cell A1 then

    =SUBSTITUTE(A1,RIGHT(A1,2),"")
    works for me, bro. Thanks or teaching me a new trick!

  7. #7
    mrtomk
    mrtomk's Avatar Become A Pro!
    Join Date: 02-24-11
    Posts: 105
    Betpoints: 771

    The above works nicely for me too, alternatively =LEFT(A1,LEN(A1)-2)

  8. #8
    brewers7
    brewers7's Avatar Become A Pro!
    Join Date: 03-11-06
    Posts: 298
    Betpoints: 4441

    Quote Originally Posted by Formulawiz View Post
    Have pitcher name
    T STAUFFER-R
    T STAUFFER-L

    Want to get rid of "-R" or "-L" in a cell and just capture the Name
    When pitchers change you dont know if it will end with the L or R

    Formula:

    An easier way to fix it is to do this:

    Do a CTRL-H and you get the Find/Replace dialog box...

    In the Find box, type:

    T STAUFFER-R

    In the Replace Box, type:

    T STAUFFER

    Then hit the "Replace All" button, and voila...

    Then do it again, but changing the R to an L and then hit "replace all" again, and you are done...

    GL...

  9. #9
    LT Profits
    LT Profits's Avatar Become A Pro!
    Join Date: 10-27-06
    Posts: 90,963
    Betpoints: 5179

    Or you can Parse by doing Data/Text to Columns/Delimited/Other "-"

  10. #10
    mrtomk
    mrtomk's Avatar Become A Pro!
    Join Date: 02-24-11
    Posts: 105
    Betpoints: 771

    Quote Originally Posted by brewers7 View Post
    Formula: An easier way to fix it is to do this: Do a CTRL-H and you get the Find/Replace dialog box... In the Find box, type: T STAUFFER-R In the Replace Box, type: T STAUFFER Then hit the "Replace All" button, and voila... Then do it again, but changing the R to an L and then hit "replace all" again, and you are done... GL...
    This isnt easier if you have a whole list of pitchers. If anything do find and replace on -R replaced with blank. You'll also have to repeat this if you ever add to the list, instead of copying the formula down.

  11. #11
    uva3021
    uva3021's Avatar Become A Pro!
    Join Date: 03-01-07
    Posts: 537
    Betpoints: 381

    Doing a find and replace might take 3 seconds longer than copying the formula down, but it saves on resources because you don't have any reoccurring calculations. You can do a find and replace on open, which would remove any key strokes.

    At some point you'll have so many calculations on your sheet its hard to even navigate the data.

  12. #12
    mrtomk
    mrtomk's Avatar Become A Pro!
    Join Date: 02-24-11
    Posts: 105
    Betpoints: 771

    Fair enough, they are both valid. It really depends on the amount of data he is using and how/how often it needs updating and manipulating.

  13. #13
    ScreaminPain
    ScreaminPain's Avatar Become A Pro!
    Join Date: 09-17-08
    Posts: 246
    Betpoints: 3172

    Quote Originally Posted by Formulawiz View Post
    Does not work. I have a name such as T WOOD-L.
    Your formula does not get rid of the "-L"
    The formula suggested doesn't work for you because you have a period after the "L". either remove the period or change the "2" in the formula to "3"......works perfectly!
    Last edited by ScreaminPain; 04-14-11 at 02:20 PM.

  14. #14
    Pokerjoe
    Pokerjoe's Avatar Become A Pro!
    Join Date: 04-17-09
    Posts: 704
    Betpoints: 307

    Find: -*
    replace with a blank.

    This way you don't have to worry about whether there's a period after the last letter, and you don't have to make separate searches for L and R.

  15. #15
    Formulawiz
    Formulawiz's Avatar Become A Pro!
    Join Date: 01-12-09
    Posts: 1,589

    Works fine. My error
    Thanks guys

Top