Github user traflm commented on a diff in the pull request: https://github.com/apache/incubator-trafodion/pull/872#discussion_r91538161 --- Diff: docs/sql_reference/src/asciidoc/_chapters/sql_functions_and_expressions.adoc --- @@ -7523,7 +7526,139 @@ TIMESTAMPDIFF (SQL_TSI_WEEK, DATE '2006-01-01', DATE '2006-01-09') ``` TIMESTAMPDIFF (SQL_TSI_DAY, DATE '2004-03-01', DATE '2004-02-01') ``` - + +<<< +[[to_date_function]] +== TO_DATE Function + +The TO_DATE function converts a character value to a date. The optional +second argument describes the format of the character value. + +``` +TO_DATE(character-expression [,format-string]) +``` + +* `_character-expression_` ++ +is an expression that gives a character value. + +* `_format-string_` ++ +is one of the following character string literals: + +** 'YYYY-MM-DD' +** 'MM/DD/YYYY' +** 'DD.MM.YYYY' +** 'YYYY-MM' +** 'MM/DD/YYYY' +** 'YYYY/MM/DD' +** 'YYYYMMDD' +** 'YY/MM/DD' +** 'MM/DD/YY' +** 'MM-DD-YYYY' +** 'YYYYMM' +** 'DD-MM-YYYY' +** 'DD-MON-YYYY' +** 'DDMONYYYY' --- End diff -- It will be helpful to have brief description of each of these 'marks'. what is difference between YY and YYYY, and it must be in upper case? It will be clear what can be valid choices for "MON" as well. But this is not a must to have, just a suggestion.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---