You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by "cscsyiku123 (via GitHub)" <gi...@apache.org> on 2023/05/17 17:01:45 UTC
[GitHub] [calcite] cscsyiku123 commented on a diff in pull request #3200: [CALCITE-5687] lazy get table scheme
cscsyiku123 commented on code in PR #3200:
URL: https://github.com/apache/calcite/pull/3200#discussion_r1196820457
##########
core/src/main/java/org/apache/calcite/schema/Schema.java:
##########
@@ -71,6 +75,8 @@ public interface Schema {
*/
Set<String> getTableNames();
+ @Nullable Table getTable(String name, boolean caseSensitive);
Review Comment:
> Why we add `caseSensitive` here? I do not get what is the relationship between it and `lazy`
1、@Nullable Table getTable(String name, boolean caseSensitive); This method only be called when your SQL references a certain table .
2、 @Nullable Table getTable(String name) can ignore case sentitive ,because the program internally processed the case sentitive in org.apache.calcite.jdbc.CachingCalciteSchema#getImplicitTable of org.apache.calcite.util.NameSet#range by org.apache.calcite.schema.impl.AbstractSchema#getTableNames provide all table names.
However , @Nullable Table getTable(String name, boolean caseSensitive) don't relies on getTableNames method ,so i add caseSensitive param.
--
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.
To unsubscribe, e-mail: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org