+ Reply to Thread
Results 1 to 3 of 3

Find alphanumeric values in one column and split alpha from numeric

  1. #1
    Registered User
    Join Date
    02-07-2013
    Location
    Tacoma, WA, USA
    MS-Off Ver
    Excel 2010
    Posts
    2

    Question Find alphanumeric values in one column and split alpha from numeric

    Hi,
    I'm working with a worksheet that was imported as a column of inconsistently alphanumeric values (doses). These problematic ones don't contain a space in one column and text (units) or blank in adjacent column:
    E F
    100 MG
    20 MG
    250MG
    25 MG
    600MG
    2SROPS
    2CAPSULES
    250 MCG

    The (F) cells with a value are okay. I want to find the combined values in E, split them so the result come out like:
    E F
    100 MG
    20 MG
    250 MG
    25 MG
    600 MG
    2 DROPS
    2 CAPSULES
    250 MCG
    (i.e., In the first row E already has the correct numeric value in column E - "100" and column F contains the associated UNIT - "MG". Now referring to the first problem child- E3 "250MG", the result in E3 should be "250" and F3 should be "MG".) I had been going through and manually adding a space to then apply the 'Text to columns' tool, but with over 1500 records, the next ice age would arrive before I could move on, so any VBA or function would be much appreciated, Thanks!
    Last edited by bowdendavid; 02-08-2013 at 03:13 PM.

  2. #2
    Forum Expert Moo the Dog's Avatar
    Join Date
    09-28-2012
    Location
    Wisconsin
    MS-Off Ver
    Office 365 (PC & Mac)
    Posts
    1,845

    Re: Find alphanumeric values in one column and split alpha from numeric

    One way... If your range starts in E2 & F2, then in cells out to the right of your data (for instance X2 & Y2), try these formulas, fill down, then copy and use Paste Special: Values over column E & F:

    X2 (Array formula, entered with Ctrl + Shift + Enter):
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Y2:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    - Moo

    * h/t to C.Pearson
    Last edited by Moo the Dog; 02-08-2013 at 04:48 PM. Reason: Modified formulas for errors...

  3. #3
    Registered User
    Join Date
    02-07-2013
    Location
    Tacoma, WA, USA
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Find alphanumeric values in one column and split alpha from numeric

    Perfect! Thanks for saving me from cold fingers!
    Cheers,
    DB

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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