[ https://issues.apache.org/jira/browse/FLINK-6847?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16551929#comment-16551929
]
ASF GitHub Bot commented on FLINK-6847:
---------------------------------------
Github user hequn8128 commented on a diff in the pull request:
https://github.com/apache/flink/pull/6282#discussion_r204230536
--- Diff: docs/dev/table/tableApi.md ---
@@ -4490,6 +4490,16 @@ dateFormat(TIMESTAMP, STRING)
</td>
</tr>
+ <tr>
+ <td>
+ {% highlight text %}
+timestampDiff(unit, timestamp1, timestamp2)
+{% endhighlight %}
+ </td>
+ <td>
+ <p>Returns the (signed) number of timeUnit intervals between timestamp1
and timestamp2. The unit for the interval is given by the unit argument, which should be one
of the following values: <code>SECOND</code>, <code>MINUTE</code>,
<code>HOUR</code>, <code>DAY</code>, <code>MONTH</code>,
or <code>YEAR</code>. E.g. <code>timestampDiff(TimeIntervalUnit.DAY, '2003-01-02'.toDate,
'2003-01-03'.toDate)</code> leads to <code>1</code>.</p>
--- End diff --
timestamp1 and timestamp2 => datetime1 and datetime2
> Add TIMESTAMPDIFF supported in TableAPI
> ---------------------------------------
>
> Key: FLINK-6847
> URL: https://issues.apache.org/jira/browse/FLINK-6847
> Project: Flink
> Issue Type: Sub-task
> Components: Table API & SQL
> Affects Versions: 1.4.0
> Reporter: sunjincheng
> Priority: Major
> Labels: pull-request-available, starter
>
> see FLINK-6813
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
|