MrExcel Message Board

Go Back   MrExcel Message Board > Question Forums > Excel Questions

Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only.

Reply
 
Thread Tools Display Modes
Old Apr 1st, 2002, 05:52 PM   #1
Jtyler
New Member
 
Join Date: Mar 2002
Location: John Tyler
Posts: 1
Default

I have a spreadsheet of inventory items. I need to calculate how many have been used of each item number. All of the item numbers are listed in column A. They have been sorted. Example A2 to A6 is part #1234. A7 to A12 starts a different item number and so on…There are 2000 cells used in column A but only 55 different item numbers. Is there a way to put the total used of each part number into a cell in column B. Many Thanks for any suggestions.

Jtyler is offline   Reply With Quote
Old Apr 1st, 2002, 06:09 PM   #2
Duane
Board Regular
 
Join Date: Mar 2002
Location: Toronto
Posts: 173
Default

There are a number of ways to do this.

So, you've got a list from A2:A2001. If you know the 55 item numbers already, you can list them in C2:C56. In D2, write =countif($A$2:$A$2001,C2) which is basically telling Excel to look through the range A2:A2001 and count all the occurances of whatever is in C2 (FYI - the dollar signs keep the range from "moving" - notice that, with no dollar signs around the C2, as you copy down, it changes to C3, C4, C5...etc...without the dollar signs, your range would have changed A3:A2002, A4:2003, etc...sometimes you want that, but in this case, you don't).

Then, copy C2 in C3:C56 and you'll have a count of all the instances of each part number in your list.

Now, if you don't know what the 55 item numbers are, then we have to find the unique values in A2:A2001. Advanced filter can handle that.

On the menu, click on Data|Filter|Advanced Filter; hit the radio button for "Copy to another location"; then, in the list range, click the little button to the right, which will take you back to the sheet with the data we want to filter, select the column A and click on the little button in the right again; now in the "copy to" field, again click on the little box in the corner, and when you're back on your sheet, select column C and hit the corner button again taking you back to the filter dialogue box; finally, make sure to click on the "unique records only" check box; and hit ok.

Now, in column C, Excel has skimmed through your list of 2000 entries and copied only the unique instances of each.

So, in column D2, enter your countif formula, copy down to D55, and you're done.

There may be many more wonderful ways to do this, but for now, this will work, and at least you've learned something that might come in handy in other tasks.

_________________
Regards, Duane

[ This Message was edited by: Duane on 2002-04-01 17:11 ]

[ This Message was edited by: Duane on 2002-04-01 17:11 ]
Duane is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 05:45 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
All contents Copyright 1998-2012 by MrExcel Consulting.
diabetic desserts recipes recipes Diabetic Soups Holiday Pizza Recipes Popcorn Recipes Recipes For Microwave Pasta Recipes Casserole Recipes Chili Recipes Curry Recipes Crockpot Recipes Apples Recipes Bread Recipes Vegetarian Recipes Vegetable recipes Desserts Recipes Appetizers Ethnic Recipes Meat Dishes Barbecue Recipes Sauces Recipes Marinade Recipes Low Fat Recipes Frugal Gourmet Kitchen Classics Recipes On The Grill Cook Books Seafood Recipes Cajun Recipes Breads Low Fat Low Fat Breads Bread Machine Recipes Yeast Breads Quick Breads Fat Free Vegetarian Salad Recipes Eggplant Recipes Radish Recipes Tomato Recipes Jalapeno Recipes Potato Recipes Lettuce Recipes Cabbage Recipes Beans Ambrosia Recipes Biscotti Recipes Desserts Low Fat Cookie Recipes Cheesecake Recipes Cake Recipes Pie Recipes Muffin Recipes Custard Recipes Best Appetizers Appetizers Low Fat Salsa Recipes Dip Recipes International Recipes Afghan Recipes Alaska Recipes French Recipes German Recipes Greek Recipes Italian Recipes Spanish Recipes Thai Recipes Korean Recipes Chinese Recipes Mexican Recipes Indian Recipes Beef Recipes Pork Pork & Ham Pork Butts Pork Chop Recipes Pork Ribs Rulled Pork Poultry Recipes Stews Recipes Ground Beef Barbecue Grill Barbecue Smoker All Purpose Sauce BBQ Sauce Barbecue Sauce Carolina BBQ Sauce Pickle Recipes Marinades Smoking Low Fat Appetizers & Dips Low Fat Breakfast Low Fat Cakes Low Fat Cheesecakes Low Fat Cookies Low Fat Desserts Low Fat Fish & Seafood Low Fat Meats Low Fat Pasta Low Fat Pies Low Fat Salads Low Fat Sandwiches Low Fat Sauces & Condiments Low Fat Sides Low Fat Soups Low Fat Vegetarian Baker's Dozen Taste of Home Recipe Book Bon Appetit Cookbook Blacktie Cookbook Buster Cook Book Cookbook USA Cook Book Cook Book Sara's Cookbook Sara's Cookbook Appetizers and Dips Poultry recipes Diabetic recipes Holiday recipes Miscellaneous recipes 110 recipes 1986 Usenet cookbook 2900 recipes Cyberrealm recipes Great sysops of world Specialty recipes Ceideburg recipes Cheese recipes Chili recipes Fruits recipes Garlic recipes Great chefs of NY Londontowne recipes Raisins recipes Recipes for kids US Food Vegetarian recipes Bread recipes Drinks Meat Dishes Brisket recipes Caribou recipes Chicken recipes Filet mignons recipes Pork recipes Swordfish recipes Turkey recipes Pasta recipes Uncategorized recipes Ethnic recipes Canada recipes English recipes Ethiopia recipes Germany recipes Greece recipes Mexican recipes Philippines recipes Welsh recipes Microwave recipes Soups recipes Vegetable recipes Asparagus recipes Barley recipes Brown rice recipes Lentil recipes Mushrooms recipes Salads recipes Wild rice Desserts recipes Cakes recipes Chocolate recipes Cookies recipes Ice cream recipes