DonnyZone commented on a change in pull request #1792: [CALCITE-3775] Implicit lookup methods in SimpleCalciteSchema ignore case sensitivity parameter URL: https://github.com/apache/calcite/pull/1792#discussion_r377520403
########## File path: core/src/main/java/org/apache/calcite/jdbc/SimpleCalciteSchema.java ########## @@ -70,28 +69,29 @@ public CalciteSchema add(String name, Schema schema) { protected CalciteSchema getImplicitSubSchema(String schemaName, boolean caseSensitive) { // Check implicit schemas. - Schema s = schema.getSubSchema(schemaName); - if (s != null) { - return new SimpleCalciteSchema(this, s, schemaName); + final NameSet names = NameSet.immutableCopyOf(schema.getSubSchemaNames()); + for (String schemaName2: names.range(schemaName, caseSensitive)) { + return new SimpleCalciteSchema(this, + schema.getSubSchema(schemaName2), schemaName); } return null; } protected TableEntry getImplicitTable(String tableName, boolean caseSensitive) { // Check implicit tables. - Table table = schema.getTable(tableName); - if (table != null) { - return tableEntry(tableName, table); + final NameSet names = NameSet.immutableCopyOf(schema.getTableNames()); + for (String tableName2: names.range(tableName, caseSensitive)) { Review comment: Could you elaborate it? Or do you mean enumerating all possibilities? E.g., converting `getTable("xy", false) ` to `getTable("XY") + getTable("Xy") + getTable("xY") +getTable("xy")`? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services