flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLINK-6960) Add E(2.7182818284590452354),PI(3.14159265358979323846) supported in SQL
Date Wed, 21 Jun 2017 08:55:00 GMT

    [ https://issues.apache.org/jira/browse/FLINK-6960?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16057203#comment-16057203
] 

ASF GitHub Bot commented on FLINK-6960:
---------------------------------------

Github user wuchong commented on a diff in the pull request:

    https://github.com/apache/flink/pull/4152#discussion_r123188958
  
    --- Diff: flink-libraries/flink-table/src/main/scala/org/apache/flink/table/functions/scalarSqlFunctions/MathSqlFunctions.scala
---
    @@ -0,0 +1,35 @@
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one
    + * or more contributor license agreements.  See the NOTICE file
    + * distributed with this work for additional information
    + * regarding copyright ownership.  The ASF licenses this file
    + * to you under the Apache License, Version 2.0 (the
    + * "License"); you may not use this file except in compliance
    + * with the License.  You may obtain a copy of the License at
    + *
    + *     http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +package org.apache.flink.table.functions.scalarSqlFunctions
    +
    +import org.apache.calcite.sql.{SqlFunction, SqlFunctionCategory, SqlKind}
    +import org.apache.calcite.sql.`type`._
    +
    +class MathSqlFunctions {
    +
    +}
    +
    +object MathSqlFunctions {
    +  val E = new SqlFunction(
    --- End diff --
    
    I would like this:
    
    ```scala
    new SqlBaseContextVariable("E", ReturnTypes.DOUBLE,
    			SqlFunctionCategory.NUMERIC);
    ```
    
    In addition, what do you think to move this file to `org/apache/flink/table/functions/utils`
?


> Add E(2.7182818284590452354),PI(3.14159265358979323846) supported in SQL
> ------------------------------------------------------------------------
>
>                 Key: FLINK-6960
>                 URL: https://issues.apache.org/jira/browse/FLINK-6960
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Table API & SQL
>            Reporter: sunjincheng
>            Assignee: sunjincheng
>              Labels: starter
>
> E=Math.E 
> PI=Math.PI



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message