+ Reply to Thread
Results 1 to 11 of 11

Formula Required to add on Numbers as required to other data

  1. #1
    Registered User
    Join Date
    02-01-2020
    Location
    UK
    MS-Off Ver
    365
    Posts
    12

    Formula Required to add on Numbers as required to other data

    Hi,

    I am currently helping someone with an innovatory spreadsheet which is to my horror nearly 15,000 lines long!

    Anyhow,

    One of the many products codes, are based on the sizes, so for example, i will have a sequence of product codes like this

    SASC00001-16 SCN0001-16
    SASC00001-18 SCN0001-18
    SASC00001-20 SCN0001-20
    SASC00001-22 SCN0001-22
    SASC00001-24 SCN0001-24
    SASC00001-28 SCN0001-28
    SASC00002-07 SCN0002-07
    SASC00002-16 SCN0002-16
    SASC00002-18 SCN0001-18
    SASC00002-20 SCN0001-20
    SASC00002-22 SCN0001-22
    SASC00002-24 SCN0001-24
    SASC00002-28 SCN0001-28
    SASC00003-07 SCN0003
    SASC00003-08 SCN0003
    SASC00003-18 SCN0003
    SASC00003-20 SCN0003
    SASC00003-22 SCN0003
    SASC00003-24 SCN0003
    SASC00003-28 SCN0003
    SASC00004-07 SCN0004
    SASC00004-08 SCN0004
    SASC00004-18 SCN0004
    SASC00004-20 SCN0004
    SASC00004-22 SCN0004
    SASC00004-24 SCN0004
    SASC00004-28 SCN0004
    SASC00005-07 SCN0005
    SASC00005-08 SCN0005
    SASC00005-18 SCN0005
    SASC00005-20 SCN0005
    SASC00005-22 SCN0005



    I basically need to be able to add the last two numbers to each of the product numbers in the second column to match those in the first column.

    Is there a way for me to use a formula to help me as there are hundreds like this to complete!
    Last edited by choccy_77; 02-01-2020 at 08:11 AM.

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    2012 for Mac at home
    Posts
    7,170

    Re: Help Required

    The assumption I am making is that what you show in red above is in cell A1 and SCN0001 is in cell B1, put this in C1
    =B1&"-"&RIGHT(A1,2) and copy down, then if needed do a copy >> paste special >> values and paste them over column B
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,966

    Re: Help Required

    Try

    =A1 & "-"&MID(A1,FIND("-",A1)+1,2) and copy down.

    You need to make the title of this thread more descriptive so that others can also make use of this solution. Something like "extracting a substring from a code and adding it to the end" would be appropriate.
    Martin

    If my solution has saved you time and/or money, please consider sponsoring my run in the 2020 London Marathon in aid of Cancer Research UK.

    https://uk.virginmoneygiving.com/MartinRice

  4. #4
    Registered User
    Join Date
    02-01-2020
    Location
    UK
    MS-Off Ver
    365
    Posts
    12

    Re: Help Required

    Quote Originally Posted by mrice View Post
    Try

    =A1 & "-"&MID(A1,FIND("-",A1)+1,2) and copy down.

    You need to make the title of this thread more descriptive so that others can also make use of this solution. Something like "extracting a substring from a code and adding it to the end" would be appropriate.

    The data will be posted into column C not B.

    The data will have numbers like this

    SASC00037-20
    SASC00037-22
    SASC00037-24
    SASC00037-28
    SASC00039
    SASC00040
    SASC00041
    SASC00042-16
    SASC00042-18
    SASC00042-20
    SASC00043-16


    So some of these below for example do not need the additional add-ons to this

    SCN0049
    SCN0049
    SCN0049
    SCN0049
    SCN0057
    SCN0058
    SCN0064
    SCN0031
    SCN0031
    SCN0031
    SCN0078

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    47,167

    Re: Help Required

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however the thread title does not really convey what your request is about.

    Please take a moment to amend your thread title. Make sure that the title properly explains your request. Your title should be explicit and not be generic (this includes function names used without an indication of what you are trying to achieve).

    Please see Forum Rule #1 about proper thread titles and adjust accordingly. To edit the thread title, open the original post to edit and then click on Go Advanced (bottom right) to access the area where you can edit your title.

    (Note: this change is not optional. I would do this for you if I were completely clear on your objective - please do it yourself.)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!

    Forum Rules (updated September 2018): please read them here.
    How to use the Power Query code you've been given: help here. More about the Power suite here.
    Don't forget to say "thank you" to those who have helped you in your thread. If you wish, you can also reward them by clicking on their reputation star bottom left.

  6. #6
    Registered User
    Join Date
    02-01-2020
    Location
    UK
    MS-Off Ver
    365
    Posts
    12

    Re: Formula Required to add on Numbers as required to other data

    Here is how I ideally need it to look


    Attachment 660600

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    47,167

    Re: Formula Required to add on Numbers as required to other data

    Thanks for the title change. Please attach the workbook itself.

  8. #8
    Registered User
    Join Date
    02-01-2020
    Location
    UK
    MS-Off Ver
    365
    Posts
    12

    Re: Formula Required to add on Numbers as required to other data

    Hi,

    I have worked out with some assistance what I need and it appears to be working ok.

  9. #9
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Ipswich, England
    MS-Off Ver
    MS 365 Business (Win 10 - Work) & MS 365 Subscription Insider (Win 10 - Home)
    Posts
    47,167

    Re: Formula Required to add on Numbers as required to other data

    OK - please share the solution you found for the benefit of all here.

    If you got the assistance from another forum, then please tell us where that was (and read our rules on cross-posting so that you are aware).

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

  10. #10
    Forum Guru Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    Excel 2010 on Linux
    Posts
    11,967

    Re: Formula Required to add on Numbers as required to other data


  11. #11
    Registered User
    Join Date
    02-01-2020
    Location
    UK
    MS-Off Ver
    365
    Posts
    12

    Re: Formula Required to add on Numbers as required to other data

    Many thanks guys,

    Sorry my timing was a factor and I barley had any usable internet access.

    I appreciate everyones assistance!

+ 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. Replies: 3
    Last Post: 07-15-2016, 12:39 PM
  2. [SOLVED] Simple Conditional Formating Help Required - If Blank then Red Bold text required
    By thilag in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 12-19-2014, 12:23 PM
  3. Help required in matching data in required format
    By pravindwd in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-04-2013, 09:03 PM
  4. Help required in matching data in required format
    By pravindwd in forum Access Tables & Databases
    Replies: 1
    Last Post: 05-04-2013, 04:11 PM
  5. For loop
    By Kazintsky in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-06-2013, 09:15 AM
  6. VB Required??
    By Anne Troy in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 09-06-2005, 07:05 AM

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