Calligra Sheets DATE Function: Construct Dates from Year, Month and Day
Create unambiguous calendar dates with DATE in Calligra Sheets. Includes argument order, month rollover, leap years, zero-input errors, locale notes and official source evidence.
Verification status: Consult the documentation, examples and any stated test scope below. How formula examples are checked
Availability and version history
- Introduced: Documented by 26.08.2; original introduction not established.
- Availability: Supported in Calligra Sheets 26.08.2, based on the function-specific registration.
- Scope: The official application listing provides Linux installation; other packaged builds are unverified here.
- Checked: October 14, 2026. Documentation/source check; no new native test in Calligra Sheets 26.08.2.
Quick answer
DATE constructs a calendar date from a year, month, and day. A common use is combining separate columns from an imported file into a date value that can be sorted or used in calculations. For example, =DATE(2024;2;29) has the independently calculated expected value February 29, 2024, rather than the text label "2024-02-29".
Version and verification scope: This guide examines Calligra Sheets 26.08.2 (released October 8, 2026), its function XML and implementation at pinned KDE commit 72123cc6, and the KDE handbook, accessed October 12, 2026. The application was not installed or executed for these examples. Dates shown below are expected calendar values from independent calculations and pinned source logic, not measured in a running Calligra spreadsheet. Display formatting will depend on locale and cell settings. KDE currently lists Linux package and Flatpak installation paths; these source checks do not establish identical behavior for all builds or platforms.
Exact syntax, argument order and types
=DATE(year;month;day)
All three arguments are required in this order. The pinned registration calls setParamCount(3); there are no optional arguments or defaults.
| Position | Parameter | Required type in KDE XML | Meaning |
|---|---|---|---|
| 1 | year |
Integer | Calendar year; use a four-digit year for portability. |
| 2 | month |
Integer | Month offset interpreted from January of that year; ordinary values are 1–12. |
| 3 | day |
Integer | Day offset interpreted from the first day of the selected month; ordinary values begin at 1. |
The KDE handbook DATE section shows semicolons; copy the separator shown by your installed Calligra formula editor if its locale conventions differ. Enter integer data in separate cells instead of relying on the interpretation of 2/3/24 or another ambiguous date string. The display might say 29/02/2024, 2/29/2024, or use a month name while the underlying value represents the same calendar day.
Return-type discrepancy: The legacy datetime.xml and handbook describe DATE as returning String/Text, but the pinned callback explicitly constructs a QDate and returns Value(tmpDate, calc->settings()), which is a date value in the engine rather than a manually concatenated string. Do not infer a particular underlying serial number or cell display solely from the XML type label. The displayed type and formatting must be checked in a native build before operational use.
Worked sheet: build dates from three imported columns
Set up a blank worksheet with A1 = Year, B1 = Month, C1 = Day, D1 = Calendar date. Type the following numbers into A2:C6. Enter =DATE(A2;B2;C2) in D2, and fill down through D6. Format column D as a date, preferably ISO-like YYYY-MM-DD for auditing. These are the independently computed expected date values:
| Row | A: Year | B: Month | C: Day | D formula, filled down | Expected date |
|---|---|---|---|---|---|
| 2 | 2024 | 2 | 29 | =DATE(A2;B2;C2) |
2024-02-29 |
| 3 | 2025 | 1 | 1 | =DATE(A3;B3;C3) |
2025-01-01 |
| 4 | 2000 | 5 | 5 | =DATE(A4;B4;C4) |
2000-05-05 |
| 5 | 2024 | 14 | 10 | =DATE(A5;B5;C5) |
2025-02-10 |
| 6 | 2024 | 2 | 31 | =DATE(A6;B6;C6) |
2024-03-02 |
The first three rows use ordinary in-range inputs. The last two deliberately demonstrate rollover, because the pinned callback initializes QDate(year,1,1), then adds month - 1 calendar months and day - 1 days. A month value of 14 therefore targets February of the following year; day 31 in February 2024 means March 2 (February has 29 days in a leap year). Rollover is inferred from the source’s QDate::addMonths/addDays sequence and independently reproduced using Gregorian arithmetic; it has not been observed in Calligra.
Tiny direct-formula checks
=DATE(2000;5;5) → expected 2000-05-05
=DATE(2024;2;29) → expected 2024-02-29
=DATE(2024;14;10) → expected 2025-02-10
These arrows annotate expected dates, not literal output strings or screenshots. Unlike text concatenation, the DATE function is intended to produce a date that other date functions can analyze.
Practical uses and advanced formulas
First day of an existing date’s month. If F2 contains an actual date constructed with =DATE(2024;2;29), enter:
=DATE(YEAR(F2);MONTH(F2);1)
Expected value: 2024-02-01. The formula combines DATE with the separate YEAR and MONTH functions. KDE documents those functions and registers them independently; they are not aliases of DATE.
Rebuild an imported YYYY/MM/DD source. When an import has numeric year, month and day columns, the D2 formula above avoids region-dependent parsing. Use a date format for the result and verify whether imported columns contain numerals or numeric-looking text before relying on type coercion.
Compare rollover to month-shifting. Given an actual date in F3 from =DATE(2024;1;31), a construction such as =DATE(YEAR(F3);MONTH(F3)+1;DAY(F3)) is expected to produce 2024-03-02 after February rollover. By contrast, =EDATE(F3;1) is expected to produce 2024-02-29, because the pinned EDATE path uses Qt’s end-of-month-adjusting QDate::addMonths. This is a genuinely important difference when calculating renewals; do not substitute DATE’s component rollover for EDATE’s month-shift semantics without testing the desired business rule.
Errors, edge cases and troubleshooting
- Month or day exactly zero: the pinned DATE callback explicitly returns a VALUE-class error for
=DATE(2024;0;15)and=DATE(2024;2;0). The precise rendered error text has not been observed. Do not useDATE(year;month;0)as a last-day-of-previous-month shortcut in this version. - Missing/extra arguments: the function registration requires three; the engine’s arity guard returns a VALUE-class error when the count differs. No default year/month/day exists.
- Month/day overflow: nonzero month/day values outside the ordinary range are passed to Qt calendar arithmetic in the examined implementation. The illustrated 14th-month and 31st-February outcomes are source-inferred; other extreme values and invalid years require native confirmation.
- Year 0 and two-digit years: Qt QDate does not recognize Gregorian year zero and interprets years 1–99 literally. Do not assume Excel’s 1900-offset handling for two-digit years applies here. Use an explicit four-digit year.
- Imported
02/03/2024text: locale-dependent parsing may swap day and month or leave a string. Prefer numeric components with DATE, and visually verify the output’s actual date formatting. DATElooks like a number or text: inspect the cell’s number/date format and underlying value type; the legacy XML type label differs from the callback. Changing formatting does not by itself change the formula.- Leap years: February 29 exists in 2024 but not in 2025. DATE uses Qt date arithmetic; use predictable modern dates and review invalid/unusual calendar inputs in the target installation.
- No native test: there is no guarantee here about plugin availability, numeric coercion of malformed text, error rendering, or exact serialization of exported spreadsheets.
Excel and other spreadsheet compatibility
Microsoft’s official Excel DATE reference also documents three arguments in year, month, day order. For ordinary four-digit dates, the conceptual use is portable. However, Excel adds 1900 for years between 0 and 1899, while the examined Calligra implementation passes the year directly into Qt QDate; Qt explicitly interprets years 1–99 literally. Excel also documents month/day normalization rules, whereas this Calligra source explicitly rejects zero month/day. These differences matter when importing formulas. The Microsoft reference was checked independently on 2026-10-12; Excel behavior is comparison evidence only, never a Calligra runtime test. The Calligra catalogue assigns no explicit alternate function name to DATE.
Official references, version and evidence trail
The following links were individually checked on October 12, 2026; line anchors refer to the pinned Calligra 26.08.2 commit rather than moving master source.
- KDE DATE handbook — function purpose, integer input order, semicolon syntax and legacy Text return description.
- KDE DATE XML — three integer parameters and documentation/example.
- KDE DATE registration — required arity of exactly three.
- KDE DATE implementation — numeric conversion, zero-argument values, Qt month/day arithmetic, date return.
- Calligra function engine argument guard — source-level VALUE-class error for wrong argument count.
- Qt QDate documentation — QDate year interpretation and addMonths/addDays calendar semantics (supporting library evidence, not Calligra execution).
- KDE Calligra Sheets application and releases — 26.08.2 published 2026-10-08 and Linux installation options.
- Microsoft Excel DATE documentation — external-platform compatibility comparison, not proof of Calligra behavior.
Testing limitation: Native Calligra locale, coercion, error display and workbook interchange have not been executed.