elasticsearch/docs/reference/sql/functions
Marios Trivyzas ead743d357
SQL: Implement DATE_PART function (#47206)
]DATE_PART(<datetime unit>, <date/datetime>) is a function that allows
the user to extract the specified unit from a date/datetime field
similar to the EXTRACT (<datetime unit> FROM <date/datetime>) but
with different names and aliases for the units and it also provides more
options like `DATE_PART('tzoffset', datetimeField)`.

Implemented following the SQL server's spec: https://docs.microsoft.com/en-us/sql/t-sql/functions/datepart-transact-sql?view=sql-server-2017
with the difference that the <datetime unit> argument is either a
literal single quoted string or gets a value from a table field, whereas
in SQL server keywords are used (unquoted identifiers) and it's not
possible to use a value coming for a table column.

Closes: #46372
2019-10-01 15:59:25 +03:00
..
aggs.asciidoc [DOCS] Remove inline callouts for Asciidoctor migration (#41309) 2019-04-22 06:33:55 -07:00
conditional.asciidoc [DOCS] Correct IIF conditional section title (#45979) 2019-08-26 11:13:18 -04:00
date-time.asciidoc SQL: Implement DATE_PART function (#47206) 2019-10-01 15:59:25 +03:00
geo.asciidoc SQL: Add support for shape type (#46464) 2019-09-25 13:43:05 -04:00
grouping.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
index.asciidoc SQL: Implement DATE_PART function (#47206) 2019-10-01 15:59:25 +03:00
like-rlike.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
math.asciidoc [DOCS] Remove inline callouts for Asciidoctor migration (#41309) 2019-04-22 06:33:55 -07:00
operators.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
search.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
string.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
system.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00
type-conversion.asciidoc [DOCS] Remove unneeded options from [source,sql] code blocks (#42759) 2019-05-31 13:03:41 -04:00