The Excel Dcount function returns the number of cells in a database field (column) that have numeric values for just chosen records. Records that fulfil a set of one or more user-specified criteria are included in the count.
Syntax :
=DCOUNT(database, [field], criterion)
Parameters :
Database :
Field :
Criterion :
A range of cells containing the criteria for determining which records should be counted. The range can comprise one or more criteria, which are displayed in one cell as a field name and the condition for that field in the cell below.
E.g. :
Subject | Age |
Math | >8 |
Example :
The Dcount function is used in the following example to count the number of Science test results obtained for male students. Cells G1 – H2 specify the conditions, and cell G3 displays the Dcount formula: The Dcount method above discovers two rows where the Gender is “Male” and the Subject is “Science.” Only one of these rows (row 13), however, has a number in the “Score” column. As a result, thfunction returns the value 1. In the above example, the Dcountfunction has omitted cell E7 from the count since it includes text rather than a number. (However, if the Dcounta function had been used instead of the Dcount function, this cell would have been counted.)
Ask Your Query