Class ShowTableRequest
org.apache.avro.generic.GenericContainer, org.apache.avro.generic.IndexedRecordGPUdb.showTable.
Retrieves detailed information about a table, view, or schema, specified in tableName. If the supplied tableName is a schema the call can return information about either the schema itself or the tables and views it contains. If tableName is empty, information about all schemas will be returned.
If the option GET_SIZES is set to TRUE, then the number of records in each table is returned (in sizes and fullSizes), along with the total number of objects across all requested tables (in totalSize and totalFullSize).
For a schema, setting the SHOW_CHILDREN option to FALSE returns only information about the schema itself; setting SHOW_CHILDREN to TRUE returns a list of tables and views contained in the schema, along with their corresponding detail.
To retrieve a list of every table, view, and schema in the database, set tableName to ’*’ and SHOW_CHILDREN to TRUE. When doing this, the returned totalSize and totalFullSize will not include the sizes of non-base tables (e.g., filters, views, joins, etc.).
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA set of string constants for theShowTableRequestparameteroptions.Constructor Summary
ConstructorsConstructorDescriptionConstructs a ShowTableRequest object with default parameters.ShowTableRequest(String tableName, Map<String, String> options) Constructs a ShowTableRequest object with the specified parameters.Method Summary
Modifier and TypeMethodDescriptionbooleanget(int index) This method supports the Avro framework and is not intended to be called directly by the user.static org.apache.avro.SchemaThis method supports the Avro framework and is not intended to be called directly by the user.Optional parameters.org.apache.avro.SchemaThis method supports the Avro framework and is not intended to be called directly by the user.Name of the table for which to retrieve the information, in [schema_name.]table_name format, using standard name resolution rules.inthashCode()voidThis method supports the Avro framework and is not intended to be called directly by the user.setOptions(Map<String, String> options) Optional parameters.setTableName(String tableName) Name of the table for which to retrieve the information, in [schema_name.]table_name format, using standard name resolution rules.toString()
Constructor Details
ShowTableRequest
public ShowTableRequest()Constructs a ShowTableRequest object with default parameters.ShowTableRequest
Constructs a ShowTableRequest object with the specified parameters.Parameters:tableName- Name of the table for which to retrieve the information, in [schema_name.]table_name format, using standard name resolution rules. If blank, then returns information about all tables and views.options- Optional parameters.DEPENDENCIES: Include view dependencies in the output. Supported values:The default value isFALSE.FORCE_SYNCHRONOUS: IfTRUEthen the table sizes will wait for read lock before returning. Supported values:The default value isTRUE.GET_ACCESS_DATA: IfTRUEthen data about the last read, write, alter and create will be returned. Supported values:The default value isFALSE.GET_CACHED_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. This version will return the sizes cached at rank 0, which may be stale if there is a multihead insert occurring. Supported values:The default value isFALSE.GET_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. Supported values:The default value isFALSE.REFERENCING_MATERIALIZED_VIEWS: Include materialized views using this table as a source in the output. Supported values:The default value isFALSE.SKIP_ADDITIONAL_INFO: IfTRUEthen the response will not populate the additional_info field. Supported values:The default value isFALSE.NO_ERROR_IF_NOT_EXISTS: IfFALSEwill return an error if the providedtableNamedoes not exist. IfTRUEthen it will return an empty result. Supported values:The default value isFALSE.SKIP_TEMP_SCHEMAS: IfTRUEthen the table list will not include tables from SYS_TEMP and other system temporary schemas. This is the default behavior for non-admin users. Supported values:The default value isFALSE.SHOW_CHILDREN: IftableNameis a schema, thenTRUEwill return information about the tables and views in the schema, andFALSEwill return information about the schema itself. IftableNameis a table or view,SHOW_CHILDRENmust beFALSE. IftableNameis empty, thenSHOW_CHILDRENmust beTRUE. Supported values:The default value isTRUE.GET_COLUMN_INFO: IfTRUEthen column info (memory usage, etc) will be returned. Supported values:The default value isFALSE.
Map.
Method Details
getClassSchema
public static org.apache.avro.Schema getClassSchema()This method supports the Avro framework and is not intended to be called directly by the user.Returns:The schema for the class.getTableName
Name of the table for which to retrieve the information, in [schema_name.]table_name format, using standard name resolution rules. If blank, then returns information about all tables and views.Returns:The current value oftableName.setTableName
Name of the table for which to retrieve the information, in [schema_name.]table_name format, using standard name resolution rules. If blank, then returns information about all tables and views.Parameters:tableName- The new value fortableName.Returns:thisto mimic the builder pattern.getOptions
Optional parameters.DEPENDENCIES: Include view dependencies in the output. Supported values:The default value isFALSE.FORCE_SYNCHRONOUS: IfTRUEthen the table sizes will wait for read lock before returning. Supported values:The default value isTRUE.GET_ACCESS_DATA: IfTRUEthen data about the last read, write, alter and create will be returned. Supported values:The default value isFALSE.GET_CACHED_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. This version will return the sizes cached at rank 0, which may be stale if there is a multihead insert occurring. Supported values:The default value isFALSE.GET_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. Supported values:The default value isFALSE.REFERENCING_MATERIALIZED_VIEWS: Include materialized views using this table as a source in the output. Supported values:The default value isFALSE.SKIP_ADDITIONAL_INFO: IfTRUEthen the response will not populate the additional_info field. Supported values:The default value isFALSE.NO_ERROR_IF_NOT_EXISTS: IfFALSEwill return an error if the providedtableNamedoes not exist. IfTRUEthen it will return an empty result. Supported values:The default value isFALSE.SKIP_TEMP_SCHEMAS: IfTRUEthen the table list will not include tables from SYS_TEMP and other system temporary schemas. This is the default behavior for non-admin users. Supported values:The default value isFALSE.SHOW_CHILDREN: IftableNameis a schema, thenTRUEwill return information about the tables and views in the schema, andFALSEwill return information about the schema itself. IftableNameis a table or view,SHOW_CHILDRENmust beFALSE. IftableNameis empty, thenSHOW_CHILDRENmust beTRUE. Supported values:The default value isTRUE.GET_COLUMN_INFO: IfTRUEthen column info (memory usage, etc) will be returned. Supported values:The default value isFALSE.
Map.Returns:The current value ofoptions.setOptions
Optional parameters.DEPENDENCIES: Include view dependencies in the output. Supported values:The default value isFALSE.FORCE_SYNCHRONOUS: IfTRUEthen the table sizes will wait for read lock before returning. Supported values:The default value isTRUE.GET_ACCESS_DATA: IfTRUEthen data about the last read, write, alter and create will be returned. Supported values:The default value isFALSE.GET_CACHED_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. This version will return the sizes cached at rank 0, which may be stale if there is a multihead insert occurring. Supported values:The default value isFALSE.GET_SIZES: IfTRUEthen the number of records in each table, along with a cumulative count, will be returned; blank, otherwise. Supported values:The default value isFALSE.REFERENCING_MATERIALIZED_VIEWS: Include materialized views using this table as a source in the output. Supported values:The default value isFALSE.SKIP_ADDITIONAL_INFO: IfTRUEthen the response will not populate the additional_info field. Supported values:The default value isFALSE.NO_ERROR_IF_NOT_EXISTS: IfFALSEwill return an error if the providedtableNamedoes not exist. IfTRUEthen it will return an empty result. Supported values:The default value isFALSE.SKIP_TEMP_SCHEMAS: IfTRUEthen the table list will not include tables from SYS_TEMP and other system temporary schemas. This is the default behavior for non-admin users. Supported values:The default value isFALSE.SHOW_CHILDREN: IftableNameis a schema, thenTRUEwill return information about the tables and views in the schema, andFALSEwill return information about the schema itself. IftableNameis a table or view,SHOW_CHILDRENmust beFALSE. IftableNameis empty, thenSHOW_CHILDRENmust beTRUE. Supported values:The default value isTRUE.GET_COLUMN_INFO: IfTRUEthen column info (memory usage, etc) will be returned. Supported values:The default value isFALSE.
Map.Parameters:options- The new value foroptions.Returns:thisto mimic the builder pattern.getSchema
public org.apache.avro.Schema getSchema()This method supports the Avro framework and is not intended to be called directly by the user.Specified by:getSchemain interfaceorg.apache.avro.generic.GenericContainerReturns:The schema object describing this class.get
This method supports the Avro framework and is not intended to be called directly by the user.Specified by:getin interfaceorg.apache.avro.generic.IndexedRecordParameters:index- the position of the field to getReturns:value of the field with the given index.Throws:put
This method supports the Avro framework and is not intended to be called directly by the user.Specified by:putin interfaceorg.apache.avro.generic.IndexedRecordParameters:index- the position of the field to setvalue- the value to setThrows: