[jira] [Created] (CALCITE-2665) JdbcMeta pads the column names for MySQL with spaces.
Yuusaku Taniguchi created CALCITE-2665:
Summary: JdbcMeta pads the column names for MySQL with spaces.
Issue Type: Bug
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.
But I think that this approach may be caused the unexpected side-effects.
This message was sent by Atlassian JIRA