DGET database function in MS Excel is very useful and important easy to use function. DGET function is used to check the given database as per your given condition and display the record which match the criteria. But if you have more than one record that matches the given condition it displays an error message on the screen. If any record does not match as per your given criteria then it displays an error message on the screen.
Syntax: =DGET(database, field, criteria)
The DGET function syntax has the following arguments:
- Database (Required): The range of cells that makes 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 (Required): Indicates which column is used in the function. Enter the column label enclosed between double quotation marks, such as “Age” or “Yield,” or a number (without quotation marks) that represents the position of the column within the list: 1 for the first column, 2 for the second column, and so on.
- Criteria (Required): The range of cells that contains the conditions that 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 in which you specify a condition for the column.
Example: Let’s look at some Excel DGET function examples and explore how to use the DGET function as a worksheet function in Microsoft Excel:
Note: The Excel DGET function gets a single value from a given field in a record that matches criteria. The database argument is a range of cells that includes field headers, field is the name or index of the field to get a max value from, and criteria is a range of cells with headers that match those in database.