[
https://issues.apache.org/jira/browse/FLINK-9999?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16578781#comment-16578781
]
ASF GitHub Bot commented on FLINK-9999:
---------------------------------------
walterddr commented on a change in pull request #6473: [FLINK-9999] [table] Add
ISNUMERIC supported in Table API/SQL
URL: https://github.com/apache/flink/pull/6473#discussion_r209719307
##########
File path:
flink-libraries/flink-table/src/test/scala/org/apache/flink/table/expressions/ScalarFunctionsTest.scala
##########
@@ -450,6 +450,63 @@ class ScalarFunctionsTest extends ScalarTypesTestBase {
"1111111111111111111111111111111111111111111111111111111111111111")
}
+ @Test
+ def testIsNumeric(): Unit = {
Review comment:
Originally what I meant is, since this function only supports
string/varchar, let's have a test that specifies `ISNUMERIC(1L)` throws
`ValidationException`.
Regarding the usage of this in general, I think this is useful to chained
with many other operators with strict type constrains. such as `CASE WHEN
ISNUMERIC(...) THEN ... ELSE ...`, where the `THEN` clause requires some strict
numeric vaues. That's why I was wondering if we should do a better support
beyond just STRING/VARCHAR type.
I will comment on the JIRA actually. thanks for bring this up.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Add ISNUMERIC supported in Table API/SQL
> ----------------------------------------
>
> Key: FLINK-9999
> URL: https://issues.apache.org/jira/browse/FLINK-9999
> Project: Flink
> Issue Type: Sub-task
> Components: Table API & SQL
> Reporter: vinoyang
> Assignee: vinoyang
> Priority: Major
> Labels: pull-request-available
>
> ISNUMERIC function used to verify a expression is a valid numberic type.
> documentation :
> https://docs.microsoft.com/en-us/sql/t-sql/functions/isnumeric-transact-sql?view=sql-server-2017
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)