Skip to main content

Excel DSUM Function

Categorized as a Database Function, the DSUM function calculates the sum of numbers from a database that match the given criteria.

dsum function 1


Syntax

=DSUM (database, field, criteria)


Arguments

  • Database (required): Database range with headers included.
  • Field (required): Column name, index number, or cell reference to count.
  • Criteria (required): Criteria range with headers included.

Return value

Numeric value.

The DSUM function returns the sum of values matching certain conditions in a database.


Function notes

  1. The DSUM function, like all other database functions, is not case-sensitive.
  2. The field argument can be a column header by its name in quotation marks, the number that indicates the position of a specific column in the database, and the cell reference of a column header.
  3. The criteria argument can be any range of cells. But it must include at least one column label and at least one cell below the column label to specify the condition. Multi-row criteria are also accepted.
  4. A variety of expressions such as wildcards can be applied in the criteria argument. Here are some examples.

    dsum function 3

  5. The purpose of the criteria argument is to filter the database and specify which records should be calculated.
  6. The column headers in the criteria range must be included in the database range.
  7. In theory, the criteria range can be located anywhere on the worksheet . But it is recommended not to be placed under the data list, in case more data need to be added.

Examples

In this case, we need to calculate the sum of all sales in the database that match the criteria. See the screenshot:

dsum function 4

To do so, please copy the formula below into cell F7 and press the Enter key to get the result.

=DSUM (B3:D11, 3, F3:H4)

dsum function 5

dsum function 6

Notes:

  1. In the above formula, we use the number that indicates the position of the sales column in the database range as the field argument, which is 3 since the sales column is at the 3rd position.
  2. We can change the value in the field argument to the column header name enclosed in quotation marks. In this case, the input value becomes “sales” in the field argument. And the formula becomes:

    =DSUM (B3:D11, "sales" , F3:H4)

  3. The field argument can also be entered as a cell reference, which is D3 in this case. So the formula changes to:

    =DSUM (B3:D11, D3 , F3:H4)


The Best Office Productivity Tools

Kutools for Excel - Helps You To Stand Out From Crowd

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates  |  Delete Blank Rows  |  Combine Columns or Cells without Losing Data  |  Round without Formula ...
Super VLookup: Multiple Criteria  |  Multiple Value  |  Across Multi-Sheets  |  Fuzzy Lookup...
Adv. Drop-down List: Easy Drop Down List  |  Dependent Drop Down List  |  Multi-select Drop Down List...
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  Compare Columns to Select Same & Different Cells ...
Featured Features: Grid Focus  |  Design View  |  Big Formula Bar  |  Workbook & Sheet Manager | Resource Library (Auto Text)  |  Date Picker  |  Combine Worksheets  |  Encrypt/Decrypt Cells  |  Send Emails by List  |  Super Filter  |  Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters ...)  |  50+ Chart Types (Gantt Chart ...)  |  40+ Practical Formulas (Calculate age based on birthday ...)  |  19 Insertion Tools (Insert QR Code, Insert Picture from Path ...)  |  12 Conversion Tools (Numbers to Words, Currency Conversion ...)  |  7 Merge & Split Tools (Advanced Combine Rows, Split Excel Cells ...)  |  ... and more

Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...

Description


Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)

  • One second to switch between dozens of open documents!
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.
Comments (0)
No ratings yet. Be the first to rate!
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations