public class CapitalizingJdbcSchema extends AbstractSchema
name, SCHEMA_SEPARATOR, schemaPath
Constructor and Description |
---|
CapitalizingJdbcSchema(List<String> parentSchemaPath,
String name,
DataSource dataSource,
org.apache.calcite.sql.SqlDialect dialect,
DrillJdbcConvention convention,
String catalog,
String schema,
boolean caseSensitive) |
Modifier and Type | Method and Description |
---|---|
boolean |
areTableNamesCaseSensitive()
Indicates if table names in schema are case sensitive.
|
CreateTableEntry |
createNewTable(String tableName,
List<String> partitionColumns,
StorageStrategy strategy)
Creates table entry using table name, list of partition columns
and storage strategy used to create table folder and files
|
void |
dropTable(String tableName) |
CapitalizingJdbcSchema |
getDefaultSchema()
The schema can be a top level schema which doesn't have its own tables, but refers
to one of the default sub schemas for table look up.
|
Set<String> |
getFunctionNames() |
Collection<org.apache.calcite.schema.Function> |
getFunctions(String name)
For the given table names returns list of acceptable table functions
which are common for all Drill schemas.
|
CapitalizingJdbcSchema |
getSubSchema(String name) |
Set<String> |
getSubSchemaNames() |
org.apache.calcite.schema.Table |
getTable(String name) |
Set<String> |
getTableNames() |
String |
getTypeName()
Returns string describing schema type which shows where the schema came from.
|
boolean |
isMutable() |
appendToStatsTable, applyFunctionParameters, close, createNewTable, createStatsTable, createView, dropView, getExpression, getFullSchemaName, getFunctionParameters, getName, getSchemaPath, getStatsTable, getSubPartitions, getTableNamesAndTypes, getTablesByNames, getType, getTypeMap, getTypeNames, getUser, needToImpersonateReadingData, showInInformationSchema, snapshot, toString
public CapitalizingJdbcSchema(List<String> parentSchemaPath, String name, DataSource dataSource, org.apache.calcite.sql.SqlDialect dialect, DrillJdbcConvention convention, String catalog, String schema, boolean caseSensitive)
public String getTypeName()
AbstractSchema
getTypeName
in class AbstractSchema
public Collection<org.apache.calcite.schema.Function> getFunctions(String name)
AbstractSchema
getFunctions
in interface org.apache.calcite.schema.Schema
getFunctions
in class AbstractSchema
name
- table namepublic Set<String> getFunctionNames()
getFunctionNames
in interface org.apache.calcite.schema.Schema
getFunctionNames
in class AbstractSchema
public CapitalizingJdbcSchema getSubSchema(String name)
getSubSchema
in interface org.apache.calcite.schema.Schema
getSubSchema
in class AbstractSchema
public Set<String> getSubSchemaNames()
getSubSchemaNames
in interface org.apache.calcite.schema.Schema
getSubSchemaNames
in class AbstractSchema
public Set<String> getTableNames()
getTableNames
in interface org.apache.calcite.schema.Schema
getTableNames
in class AbstractSchema
public CreateTableEntry createNewTable(String tableName, List<String> partitionColumns, StorageStrategy strategy)
AbstractSchema
createNewTable
in class AbstractSchema
tableName
- : new table name.partitionColumns
- : list of partition columns. Empty list if there is no partition columns.strategy
- : storage strategy used to create table folder and filespublic void dropTable(String tableName)
dropTable
in class AbstractSchema
public boolean isMutable()
isMutable
in interface org.apache.calcite.schema.Schema
isMutable
in class AbstractSchema
public org.apache.calcite.schema.Table getTable(String name)
getTable
in interface org.apache.calcite.schema.Schema
getTable
in class AbstractSchema
public boolean areTableNamesCaseSensitive()
AbstractSchema
areTableNamesCaseSensitive
in class AbstractSchema
public CapitalizingJdbcSchema getDefaultSchema()
AbstractSchema
Default implementation returns itself.
Ex. "dfs" schema refers to the tables in "default" workspace when querying for tables in "dfs" schema.
getDefaultSchema
in class AbstractSchema
Copyright © 1970 The Apache Software Foundation. All rights reserved.