0
0
Google Sheetsspreadsheet~10 mins

YEAR, MONTH, DAY extraction in Google Sheets - Cell-by-Cell Formula Trace

Choose your learning style9 modes available
Sample Data

This table shows dates in column A. Columns B, C, and D will extract the year, month, and day from each date.

CellValue
A1Date
A22024-06-15
A32023-12-01
A42022-01-31
B1Year
C1Month
D1Day
Formula Trace
=YEAR(A2)
Step 1: A2
Step 2: YEAR("2024-06-15")
Cell Reference Map
    A       B       C       D
1 | Date  | Year  | Month | Day  |
2 | 2024-06-15 -> YEAR()  |       |       |
3 | 2023-12-01          |       |       |
4 | 2022-01-31          |       |       |
The formula references cell A2 to extract the year.
Result
    A           B     C     D
1 | Date      | Year | Month | Day |
2 | 2024-06-15| 2024 |       |     |
3 | 2023-12-01|      |       |     |
4 | 2022-01-31|      |       |     |
The YEAR function in B2 shows 2024, extracted from the date in A2.
Sheet Trace Quiz - 3 Questions
Test your understanding
What does the formula =YEAR(A2) return if A2 contains 2024-06-15?
A2024
B6
C15
D06-15
Key Result
YEAR(date) extracts the year, MONTH(date) extracts the month, and DAY(date) extracts the day from a date value.