date_format.asciidoc 324 B

123456789101112
  1. [discrete]
  2. [[esql-date_format]]
  3. === `DATE_FORMAT`
  4. Returns a string representation of a date in the provided format. If no format
  5. is specified, the `yyyy-MM-dd'T'HH:mm:ss.SSSZ` format is used.
  6. [source,esql]
  7. ----
  8. FROM employees
  9. | KEEP first_name, last_name, hire_date
  10. | EVAL hired = DATE_FORMAT("YYYY-MM-dd", hire_date)
  11. ----