[jira] [Updated] (CALCITE-2663) CREATE FUNCTION SQL STAMENT

2018-11-11 Thread ambition (JIRA)


 [ 
https://issues.apache.org/jira/browse/CALCITE-2663?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ambition updated CALCITE-2663:
--
Fix Version/s: 1.16.0

> CREATE FUNCTION SQL STAMENT
> ---
>
> Key: CALCITE-2663
> URL: https://issues.apache.org/jira/browse/CALCITE-2663
> Project: Calcite
>  Issue Type: Improvement
>  Components: core
>Affects Versions: 1.16.0, 1.17.0
>Reporter: ambition
>Assignee: Julian Hyde
>Priority: Minor
> Fix For: 1.16.0, 1.17.0
>
>
> support create function statement like hive:
>  
>  
> {code:java}
> CREATE FUNCTION [db_name.]function_name AS class_name
>   [USING JAR|FILE|ARCHIVE 'file_uri' [, JAR|FILE|ARCHIVE 'file_uri'] ];
> {code}
>  
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (CALCITE-2663) CREATE FUNCTION SQL STAMENT

2018-11-11 Thread ambition (JIRA)


 [ 
https://issues.apache.org/jira/browse/CALCITE-2663?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ambition updated CALCITE-2663:
--
Affects Version/s: 1.16.0

> CREATE FUNCTION SQL STAMENT
> ---
>
> Key: CALCITE-2663
> URL: https://issues.apache.org/jira/browse/CALCITE-2663
> Project: Calcite
>  Issue Type: Improvement
>  Components: core
>Affects Versions: 1.16.0, 1.17.0
>Reporter: ambition
>Assignee: Julian Hyde
>Priority: Minor
> Fix For: 1.17.0
>
>
> support create function statement like hive:
>  
>  
> {code:java}
> CREATE FUNCTION [db_name.]function_name AS class_name
>   [USING JAR|FILE|ARCHIVE 'file_uri' [, JAR|FILE|ARCHIVE 'file_uri'] ];
> {code}
>  
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (CALCITE-2665) JdbcMeta pads the column names for MySQL with spaces.

2018-11-11 Thread Yuusaku Taniguchi (JIRA)
Yuusaku Taniguchi created CALCITE-2665:
--

 Summary: JdbcMeta pads the column names for MySQL with spaces.
 Key: CALCITE-2665
 URL: https://issues.apache.org/jira/browse/CALCITE-2665
 Project: Calcite
  Issue Type: Bug
  Components: avatica
Affects Versions: avatica-1.12.0
 Environment: My environment that confirmed this problem is as follows.

- Avatica 1.12.0
- MySQL 8.0.12
- mysql-connector-java 8.0.12
Reporter: Yuusaku Taniguchi


I tried to connect to Avatica's StandaloneServer using with Avatica remote JDBC 
driver. The column names which come out of AvaticaDatabaseMetaData#getColumns 
method are padded with spaces using with FixedStringAccessor. This problem is 
caused by JdbcMeta#getColumns method on the server side. Because 
DatabaseMetaData#getColumns method of MySQL JDBC driver returns 1 
(java.sql.Types.CHAR) as the value of DATA_TYPE column.

I want to get no-padding column names on the client side. How do I write the 
patches for this problem? Most simply patches is that it use StringAccessor as 
default CHAR accessor instead of FixedStringAccessor.

https://github.com/apache/calcite-avatica/blob/rel/avatica-1.12.0/core/src/main/java/org/apache/calcite/avatica/util/AbstractCursor.java#L128

But I think that this approach may be caused the unexpected side-effects.




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)