From 00b56bf007dde3951ff85820c57c30d719ee56e6 Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Thu, 20 Aug 2020 13:51:57 -0700 Subject: [PATCH] Add note about negative epoch times (#61379) This commit adds a reminder to date type documentation that negative epoch times are not supported. relates #40983 --- docs/reference/mapping/types/date.asciidoc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/reference/mapping/types/date.asciidoc b/docs/reference/mapping/types/date.asciidoc index 075ab0cf80a..f5afa581631 100644 --- a/docs/reference/mapping/types/date.asciidoc +++ b/docs/reference/mapping/types/date.asciidoc @@ -10,6 +10,9 @@ JSON doesn't have a date data type, so dates in Elasticsearch can either be: * a long number representing _milliseconds-since-the-epoch_. * an integer representing _seconds-since-the-epoch_. +NOTE: Values for _milliseconds-since-the-epoch_ and _seconds-since-the-epoch_ +must be non-negative. Use a formatted date to represent dates before 1970. + Internally, dates are converted to UTC (if the time-zone is specified) and stored as a long number representing milliseconds-since-the-epoch.