+ Reply to Thread
Results 1 to 2 of 2

Trying to match product colors based on order numbers

  1. #1
    Registered User
    Join Date
    04-10-2014
    Location
    USA
    MS-Off Ver
    Excel 2003
    Posts
    7

    Trying to match product colors based on order numbers

    I have a customer order sheet with order numbers and color selection. All products are the same other than color selection. Customers with multiple orders are displayed 1 per line. So there will be 3 orders for example with the same order number and three different colors displayed on 3 rows.

    I need to put all 3 colors in 1 field for each order. The idea is to make shipping easier by only having to reference 1 line to see what colors were ordered. Here's an example of what I have:

    Order Number Color Name
    100107545 black mark
    100107545 light grey mark
    100107548 black gary
    100107551 white rich
    100107559 light grey rich
    100107559 beige paul
    100107560 black paul
    100107560 coffee Paul

    This is what I need:

    Order Number Color Name Results
    100107545 black mark black, light grey
    100107545 light grey mark
    100107548 black gary black
    100107551 white rich white, light grey
    100107559 light grey rich
    100107559 beige paul beige, black, coffee
    100107560 black paul
    100107560 coffee Paul

    I'm hoping there is just a simple formula I can copy down the sheet. Don't understand macros so not a big fan there.

    Thanks!

  2. #2
    Valued Forum Contributor
    Join Date
    11-22-2014
    Location
    Arizona, USA
    MS-Off Ver
    Office 365
    Posts
    973

    Re: Trying to match product colors based on order numbers

    No to VBA? would be easier...but if you are strict on macro free workbooks you will need to spend time making 2 helper columns.

    If your list exists in A and B, insert 2 columns, so now your lists live in C and D.

    Inside A you will say (Assuming C is your order numbers)

    A2 =
    Please Login or Register  to view this content.
    That will give you a Unique order number to lookup

    Now in B again assuming C is your Orders
    B2=
    Please Login or Register  to view this content.
    This will give you the order number with its count also for lookup but this time used for looking up your colors which is being assumed in D by now...


    Now either off to the right or on a separate sheet (Lets keep it to this sheet for now) you will build a list of orders.

    Let's say in F you put a list of numbers from 1 - 100
    OrderID|Order Number | Colors
    1
    2
    3
    4
    5
    6
    7
    8
    9
    etc...

    The numbers are static so write them in down to as many as you think you need. for the Order number we will perform a VLookup From A to C (3 columns) to pull the unique Order Number
    G2=
    Please Login or Register  to view this content.
    Now you have a list of Order Numbers without duplicates.

    Next let's pull in the colors, you said a max of 3, just keep in mind you can add as many as you think is necessary...just add another nested IF in the following
    H2=
    Please Login or Register  to view this content.
    So what I am doing here is looking up the Order you just pulled into G combined with a -1,-2,-3 for the first, second, third instance (Again add another if you believe you will need them!)
    Take note of the &"," before the second and third Vlookup in the formula. This will add a comma IF there is another color to add to the order, that way you are not left with excessive commas...
    -If you think you are done, Start over - ELeGault

+ 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. Show Variance in Inventory based on Product Numbers
    By msdclark in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 08-28-2014, 10:28 AM
  2. Replies: 1
    Last Post: 06-20-2014, 03:38 PM
  3. Invoicing based on product and order number
    By MOONDRIFT47 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-01-2014, 10:36 AM
  4. Assigning Bar Charts Different Colors based on RGB Numbers in Table with VBA Macro
    By waller99 in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 05-01-2014, 08:49 AM
  5. Replies: 10
    Last Post: 09-27-2012, 03:59 PM

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