You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Serge Harnyk (JIRA)" <ji...@apache.org> on 2016/03/28 15:37:25 UTC
[jira] [Commented] (DRILL-4458) JDBC plugin case sensitive table
names
[ https://issues.apache.org/jira/browse/DRILL-4458?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15214195#comment-15214195 ]
Serge Harnyk commented on DRILL-4458:
-------------------------------------
Its bug of current version of Calcite that Drill uses:
@Override
public TableEntry getTable(String tableName, boolean caseSensitive) {
Table t = schema.getTable(tableName);
if (t == null) {
TableEntry e = tableMap.get(tableName);
if (e != null) {
t = e.getTable();
}
}
if (t != null) {
return new TableEntryImpl(this, tableName, t, ImmutableList.<String>of());
}
return null;
}
argument caseSensitive doesnt used anywhere in this method
In last version of Calcite this bug is fixed:
https://github.com/apache/calcite/blob/master/core/src/main/java/org/apache/calcite/jdbc/CalciteSchema.java
> JDBC plugin case sensitive table names
> --------------------------------------
>
> Key: DRILL-4458
> URL: https://issues.apache.org/jira/browse/DRILL-4458
> Project: Apache Drill
> Issue Type: Bug
> Components: Storage - JDBC
> Affects Versions: 1.5.0
> Environment: Drill embedded mode on OSX, connecting to MS SQLServer
> Reporter: Paul Mogren
> Assignee: Serge Harnyk
> Priority: Minor
>
> I just tried Drill with MS SQL Server and I found that Drill treats table
> names case-sensitively, contrary to
> https://drill.apache.org/docs/lexical-structure/ which indicates that
> table names are "case-insensitive unless enclosed in double quotation
> marks”. This presents a problem for users and existing SQL scripts that
> expect table names to be case-insensitive.
> This works: select * from mysandbox.dbo.AD_Role
> This does not work: select * from mysandbox.dbo.ad_role
> Mailing list reference including stack trace: http://mail-archives.apache.org/mod_mbox/drill-user/201603.mbox/%3cCAJrw0OTv8N5yBMvu6W_Efe4nPGeNRdK5GRMH9jTBxu9xnNifNQ@mail.gmail.com%3e
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)