+ Reply to Thread
Results 1 to 12 of 12

How to add suffix to cell in an fixed interval

  1. #1
    Registered User
    Join Date
    10-01-2014
    Location
    uk
    MS-Off Ver
    2013
    Posts
    29

    How to add suffix to cell in an fixed interval

    Hello,

    I have a list of Items with codes.
    NAME CODE
    Product A ABC
    Product B ABC

    I would like to add X (probably 5) different suffixes to the code. For example, I would to add to ABC-01, ABC-02 and so on until ABC-05.

    NAME CODE
    Product A ABC-01
    Product B ABC-02

    All the codes will have the some suffix added to them.

    Doing this manually will take me a full day (100s of products)

    Any ideas?

    Thank you

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,053

    Re: How to add suffix to cell in an fixed interval

    Are there any rules that define which suffix is added? Can this be linked to either the name or the code? If not, then I think that you'll have todothis at least partially manually...
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: How to add suffix to cell in an fixed interval

    Try this one

    =B1&"-"&TEXT(ROWS(B$1:B1),"00")

    Row\Col
    A
    B
    C
    1
    Product A ABC ABC-01
    2
    Product B ABC ABC-02
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  4. #4
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: How to add suffix to cell in an fixed interval

    It is confusing that you say you will add probably 5 different suffixes and then say that all the codes will have the same suffix. Can you upload an example of maybe 30 lines showing what you have now and what you would expect to have. (and why if it's not clear). Go Advanced>Manage Attachments.
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  5. #5
    Registered User
    Join Date
    10-01-2014
    Location
    uk
    MS-Off Ver
    2013
    Posts
    29

    Re: How to add suffix to cell in an fixed interval

    It is confusing that you say you will add probably 5 different suffixes and then say that all the codes will have the same suffix. Can you upload an example of maybe 30 lines showing what you have now and what you would expect to have. (and why if it's not clear). Go Advanced>Manage Attachments.
    Here is the sheet and explanation:

    sheet.xlsx

  6. #6
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: How to add suffix to cell in an fixed interval

    in F4 and copy down

    =B4&"-"&TEXT(COUNTIF(E$4:E4,E4),"00")

  7. #7
    Registered User
    Join Date
    10-01-2014
    Location
    uk
    MS-Off Ver
    2013
    Posts
    29

    Re: How to add suffix to cell in an fixed interval

    Thank you.

    Furthermore:

    If I have a list a products like seen, how to I duplicate each product 5 times?

    So instead of having:
    Product 1
    Product 2
    Product 3

    I'll have:

    Product 1
    Product 1
    Product 1
    Product 1
    Product 1
    Product 2
    Product 2
    Product 2
    Product 2
    Product 2
    Product 3
    Product 3
    Product 3
    Product 3
    Product 3

    And then I could apply the formula you suggested above.

    Thank you

  8. #8
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: How to add suffix to cell in an fixed interval

    If Product1 let's say, listed 5 times the formula will do 01,02,03,04,05 if listed 3 times then 01,02,03

  9. #9
    Registered User
    Join Date
    10-01-2014
    Location
    uk
    MS-Off Ver
    2013
    Posts
    29

    Re: How to add suffix to cell in an fixed interval

    I understand,

    But, as you can see in the sheet, all the products are listed just once, but I need to duplicate each 4 more times to create total of 5 instances of each, because I want 5 different suffixes. How can I also duplicate quickly without having to copy and paste each one?

    Again, I have a list of 500(+-) products from product 1 to product 500. Each appears just once. I need to duplicate each one to a total of 5, and add 5 different suffices to each.

    I hope Im making myself clear

  10. #10
    Registered User
    Join Date
    10-01-2014
    Location
    uk
    MS-Off Ver
    2013
    Posts
    29

    Re: How to add suffix to cell in an fixed interval

    also, the product have actual names and not numbers like so:

    LEMON
    BOTTLE
    BLUE SHIRT
    CELL PHONE

  11. #11
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: How to add suffix to cell in an fixed interval

    Not really sure what you need at this point. Do you simply want to repeat the number of times product name?

  12. #12
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: How to add suffix to cell in an fixed interval

    Select the entire range (AA4:B23) and copy and paste it below itself, repeat 3 more times. Then if you want, you can sort by column A to bring all of Product 1 together.

+ 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. Macros for deleting rows in a fixed interval
    By divkar in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 04-22-2014, 05:03 PM
  2. Counting formula to sum values over a fixed interval
    By aart008 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-08-2014, 02:50 AM
  3. [SOLVED] Changing a positive or negative value based on the input's suffix, then removing suffix
    By Theredwind in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-06-2014, 05:19 AM
  4. Fixed cells interval
    By vitaleg in forum Excel General
    Replies: 4
    Last Post: 09-18-2010, 04:00 PM
  5. Fixed Interval Ordering Function
    By Kyle Hansen in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 07-01-2009, 09:37 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