ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Search and present lists (https://www.excelbanter.com/excel-worksheet-functions/235914-search-present-lists.html)

SwEdIsH_OfFiCe_UsEr

Search and present lists
 
I have a problem in two steps.

Step 1:
I have one ID column and one column with numbers. The same ID may appear
several times, but all ID's must not be included (depending on other
variables) What I want is to use something similar to the LOOKUP function,
but that returns All values of the given ID (not just the first one) and add
them together. What function should I use and how?

Step 2:
I want to create a third list that includes only the ID's which were
included in the ID column, the sum of the numbers that they were connected
with and preferrably sort them in falling order based on the numbers column.
How do I do this?

Jacob Skaria

Search and present lists
 
Suppose you have ID in colA and numbers in ColB; the below formula will
return the sum of values in ColB for ID 123

=SUMIF(A:A,123,B:B)

Change 123 to whatever is your ID in ColA. If your ID is in text format like
A123 then use double quotes like
=SUMIF(A:A,"A123",B:B)
OR refer that to a cell
C1 = A123
=SUMIF(A:A,C1,B:B)

For your second question; try DataFilter option


If this post helps click Yes
---------------
Jacob Skaria


"SwEdIsH_OfFiCe_UsEr" wrote:

I have a problem in two steps.

Step 1:
I have one ID column and one column with numbers. The same ID may appear
several times, but all ID's must not be included (depending on other
variables) What I want is to use something similar to the LOOKUP function,
but that returns All values of the given ID (not just the first one) and add
them together. What function should I use and how?

Step 2:
I want to create a third list that includes only the ID's which were
included in the ID column, the sum of the numbers that they were connected
with and preferrably sort them in falling order based on the numbers column.
How do I do this?



All times are GMT +1. The time now is 08:44 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com