+ Reply to Thread
Results 1 to 11 of 11

Highlighting when stock is low if there are several entries (batches) of same product

  1. #1
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Question Highlighting when stock is low if there are several entries (batches) of same product

    I'm working on a stock sheet which lists products, their batch numbers, number of products left, and various other information.

    Sometimes there are several different entries of the same product number but with different batch numbers. (The number of entries for the same product can go up and down as stock is used up and more is bought in.)

    For each product, there is a specific quantity when, if stock goes below that number, more stock should be ordered.

    I want excel to highlight whenever a product goes below its specific quantity.

    What is the best way to do this, when there are often several entries for the same product, and the number of entries can vary?

    I'd really appreciate your help!
    (Do say if I need to explain this in more detail.)

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Where does excel look for those minimum quantities?

    Can you upload a sample workbook?
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Thanks for replying. Here's a sample workbook.

    The minimum quanties are in the same row as the the other product details.
    Attached Files Attached Files

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    You have no entries in Min Qty column. Will you be entering them in as you go?

    For Oranges, will you be entering same min quantity in each row?

    Are you going to be entering negative quantities in column H to indicate stock taken out?

    Please update your sample with more items showing possible types of entries... then show sample of what you want highlighted and why.

  5. #5
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    There will be minimum quantities written for each product as they come in.

    Yes the batches of the same product will all have the same minimum quantity. The minimum quantity will apply to all batches as a whole so if there are 2 batches of oranges each at 100kg, and the minimum quantity is 100kg, that is well above the minimum quantity; only once they reach a sum total of 100kg, e.g. 50kg of each batch, do I want it to be highlighted.

    There won't be any negative quantities - the Qty. should say the actual amount of stock left. I added the total quantity column thinking it might be come in useful at some point for this job of highlighting when stock is low. I thought maybe a formula could automatically enter the total quantities in that column. But it may or may not be helpful.

    I've updated the workbook with more information.

    Everything's been entered manually but I would want it to automatically say Yes or in the Low Stock Column if appropriate.

    For example,
    Oranges: Min Qty = 60. There are 2 batches, 5 left of one, 50 left of the other. Total = 55, so I would like it to say yes in the Low Stock column.

    Pears: Min Qty = 20. There are 2 batches, one batch has 10, one has 120. Total = 130, so I'd like it to say no in the Low Stock column.

  6. #6
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Sorry I forgot to attach...
    Attached Files Attached Files

  7. #7
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    In I5, enter:

    =SUMIF(B:B,B5,H:H)

    copied down

    and in M5 enter:

    =IF(I5<G5,"Yes","No")

    copied down.

    To highlight the Yes

    Select the range... either all the columns or a specific column you want to highlight and go to Format|Conditional Formatting and select Formula Is from 1st drop down.

    Enter formula =$M5="Yes"

    assuming you selected your range starting at row 5.

    then click Format and choose colour from Pattern tab.

  8. #8
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Thank you for your help, everything after the first formula is just what I need.

    For the first part though, the number of batches of the one product can vary - at one time there may be one batch, at another there may be additional rows inserted for several batches.

    Is there some way to make it search through the list for entries with the same product number and add up their quantities automatically?

  9. #9
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Use the same function:

    =SUMIF(C:C,C5,H:H)

    where C:C is column of product nos. C5 is first product number to match and H:H represents column to sum, i.e. H.

  10. #10
    Registered User
    Join Date
    07-29-2010
    Location
    Western Isles, Scotland, UK
    MS-Off Ver
    Excel 2003 & sometimes 2007
    Posts
    22

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    Oh fantastic!! Thanks so much!

  11. #11
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Highlighting when stock is low if there are several entries (batches) of same pro

    The formula you said you did not use earlier was included to hopefully reduce your workload to manually enter the total quantities.. the SUMIF will do it for you..... just FYI

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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