Excel DAY Function
The DAY function in Microsoft Excel extracts the day component from a date as a number from 1 to 31. It is useful for analyzing or formatting date-based data, such as sorting by day.
Key Topics
Overview of DAY Function
The DAY function returns the day of the month from a given date, enabling easy extraction for calculations or reporting. It is often used with other date functions for custom date manipulations.
DAY Function Syntax
The syntax for the DAY function is as follows:
Syntax: =DAY(serial_number)
Parameters:
- serial_number: The date or cell reference containing a date (required).
Implementation Examples
Below are examples of how to use the DAY function in different scenarios.
Example 1: =DAY(B2)
— Extracts the day from the date in B2.
Example 2: =DAY(TODAY())
— Returns the day of the current date.
Example 3: =DAY(DATE(2025, 6, 3))
— Returns 3, the day from 06/03/2025.
Sample Dataset (Excel-style View)
Below is a demo dataset styled like Excel, showing how the DAY function can be used to extract the day from order dates.
A | B | C | |
---|---|---|---|
1 | Order ID | Order Date | Day of Order |
2 | ORD001 | 06/03/2025 | =DAY(B2) |
3 | ORD002 | 06/15/2025 | =DAY(B3) |
4 | ORD003 | 06/22/2025 | =DAY(B4) |
5 | ORD004 | 06/01/2025 | =DAY(B5) |
6 | ORD005 | 06/30/2025 | =DAY(B6) |
Note: In the dataset, column C uses =DAY(B2)
to extract the day from the order date in B2. The formula is applied to each row to show the day of each order.
Key Takeaways
- The DAY function extracts the day (1–31) from a date.
- It works with dates, TODAY(), or DATE function outputs.
- It is useful for sorting or analyzing date-based data by day.
- Common uses include reporting order days or scheduling tasks.
- The sample dataset demonstrates DAY applied to extract order days.