Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dsum function in Excel

Status
Not open for further replies.

Thorny

Programmer
Jul 2, 2001
23
GB
Can anyone give me an example of a how the Dsum function is used in excel? Thanks
 
Have you tried the help in Excel, its really straight forward. Dsum adds the numbers in a column in a list or database that match conditions you specify.

DSUM(database,field,criteria) is the formula in your cell.

Database (B1:E6) is the range of cells that make up the list or database. A database is a list of related data in which rows of related information are records and columns of data are fields. The first row of the list contains labels for each column.

Field indicates which column is used in the function. Field can be given as text with the column label enclosed between double quotation marks, such as "Age" or "Yield," or as a number that represents the position of the column within the list: 1 for the first column, 2 for the second column, and so on.

Criteria (B7:E8) is the range of cells that contains the conditions you specify. You can use any range for the criteria argument, as long as it includes at least one column label and at least one cell below the column label for specifying a condition for the column.

B C D E
1 Name Age Years Salary
worked
2 Smith 21 3 15000
3 Jones 43 13 27000
4 Brown 43 23 34000
5 Green 27 2 23000
6 Black 39 23 28000
7 Name Age Years Salary
worked
8 >27
9 89000
10 =DSUM(B1:E6,"Salary",B7:E8)

In the above example, the formula is shown in C10 with the answer in the cell above. What we are doing is adding up all the salaries of people whose age is greater than 27 (criteria set in cell C8) to receive an answer of 89,000.

Hope you can read this OK, I couldn't find the way of pasting an excel worksheet into the answer box. No doubt someone wil now tell me!


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top