Quick Answer

DAVERAGE Function

Averages the values in a database column for rows that meet the criteria.

✓ Excel✓ Google SheetsExcel All versions

Syntax

DAVERAGE
(database, field, criteria)

Parameters

ParameterDescriptionRequired
databaseThe range containing the database, including the header row as the first row.Required
fieldThe column to average, given as the column label in quotes (e.g. "Yield") or its 1-based column index.Required
criteriaThe range with a header row matching database column names and one or more condition rows; only matching records are averaged.Required

Basic Example

Average the Yield of apple trees taller than 10

=DAVERAGE(A1:E7, "Yield", A9:B10)
Result12

The criteria A9:B10 (Tree=Apple, Height>10) matches two rows with Yield 14 and 10; the mean is (14+10)/2 = 12.

Advanced Examples

Example 1: Average a different column

Average Profit for the same matching trees

Change only the field to Profit (column 5).

=DAVERAGE(A1:E7, "Profit", A9:B10)
Result: 90
The two matching rows have Profit 105 and 75, so the average is (105+75)/2 = 90.

Example 2: Single matching record

Average Yield for cherry trees

With criteria Tree=Cherry, only one record matches, so the average equals that value.

=DAVERAGE(A1:E7, "Yield", A9:A10)
Result: 9
Only the cherry row (Yield 9) matches, so the mean is 9.

How DAVERAGE Works

DAVERAGE filters the database to rows matching the criteria, sums the numeric values in the specified field, and divides by the count of those numeric values. Text and blank cells in the field are excluded from both the sum and the count.

1
Set up the database
Enter your table with a header row, e.g. A1:E7 with Tree, Height, Age, Yield, Profit.
2
Set up criteria
Place criteria headers and values in a separate range, e.g. A9:B10.
3
Enter DAVERAGE
Type =DAVERAGE(A1:E7, "Yield", A9:B10) and press Enter.

Important Notes & Limitations

  • Only numeric values in the field are considered; text and blanks are ignored.

  • If no records match, DAVERAGE returns the #DIV/0! error.

  • Criteria header labels must exactly match database headers.

Common Errors & Fixes

#DIV/0!No records matched the criteria, so the count of numeric values was zero.

Fix: Check the criteria so at least one record matches, or verify header spelling.

#VALUE!The field was an unquoted column name.

Fix: Wrap the field name in quotes, e.g. "Yield", or use the column index.

Download Practice File

Practice DAVERAGE with Real Data

Download a sample CSV file with pre-populated data and practice exercises for the DAVERAGE function. Works in both Excel and Google Sheets.

Works in Google SheetsCompatible with ExcelIncludes exercises

File format: CSV (comma-separated values) - opens in Excel, Google Sheets, and all spreadsheet apps

Frequently Asked Questions

Does DAVERAGE include blank cells in the count?
No. Only numeric values in the matching rows are counted and averaged.
What happens with a single matching record?
The average equals that one value.
How is DAVERAGE different from AVERAGEIF?
DAVERAGE filters a multi-column database by a full criteria range, while AVERAGEIF applies a single condition to one range.