public class MergeRecordsRequest extends Object implements org.apache.avro.generic.IndexedRecord
GPUdb.mergeRecords(MergeRecordsRequest).
 
 Create a new empty result table (specified by tableName),
 and insert all records from source tables
 (specified by sourceTableNames) based on the field mapping
 information (specified by fieldMaps).
 
 For merge records details and examples, see
 Merge
 Records.  For limitations, see
 Merge Records Limitations and Cautions.
 The field map (specified by fieldMaps) holds the user-specified maps
 of target table column names to source table columns. The array of
 fieldMaps must match one-to-one with the sourceTableNames,
 e.g., there's a map present in fieldMaps for each table listed in
 sourceTableNames.
| Modifier and Type | Class and Description | 
|---|---|
| static class  | MergeRecordsRequest.OptionsOptional parameters. | 
| Constructor and Description | 
|---|
| MergeRecordsRequest()Constructs a MergeRecordsRequest object with default parameters. | 
| MergeRecordsRequest(String tableName,
                   List<String> sourceTableNames,
                   List<Map<String,String>> fieldMaps,
                   Map<String,String> options)Constructs a MergeRecordsRequest object with the specified parameters. | 
| Modifier and Type | Method and Description | 
|---|---|
| boolean | equals(Object obj) | 
| Object | get(int index)This method supports the Avro framework and is not intended to be called
 directly by the user. | 
| static org.apache.avro.Schema | getClassSchema()This method supports the Avro framework and is not intended to be called
 directly by the user. | 
| List<Map<String,String>> | getFieldMaps() | 
| Map<String,String> | getOptions() | 
| org.apache.avro.Schema | getSchema()This method supports the Avro framework and is not intended to be called
 directly by the user. | 
| List<String> | getSourceTableNames() | 
| String | getTableName() | 
| int | hashCode() | 
| void | put(int index,
   Object value)This method supports the Avro framework and is not intended to be called
 directly by the user. | 
| MergeRecordsRequest | setFieldMaps(List<Map<String,String>> fieldMaps) | 
| MergeRecordsRequest | setOptions(Map<String,String> options) | 
| MergeRecordsRequest | setSourceTableNames(List<String> sourceTableNames) | 
| MergeRecordsRequest | setTableName(String tableName) | 
| String | toString() | 
public MergeRecordsRequest()
public MergeRecordsRequest(String tableName, List<String> sourceTableNames, List<Map<String,String>> fieldMaps, Map<String,String> options)
tableName - The name of the new result table for the records to be
                   merged into, in [schema_name.]table_name format, using
                   standard name resolution rules and meeting table naming criteria.  Must NOT be
                   an existing table.sourceTableNames - The list of names of source tables to get the
                          records from, each in [schema_name.]table_name
                          format, using standard name resolution rules.  Must
                          be existing table names.fieldMaps - Contains a list of source/target column mappings, one
                   mapping for each source table listed in sourceTableNames being merged into the target table
                   specified by tableName.  Each mapping contains
                   the target column names (as keys) that the data in the
                   mapped source columns or column expressions (as values) will be
                   merged into.  All of the source columns being merged
                   into a given target column must match in type, as that
                   type will determine the type of the new target column.options - Optional parameters.
                 CREATE_TEMP_TABLE: If true, a unique temporary
                 table name will be generated in the sys_temp schema and
                 used in place of tableName. If persist
                 is false, then this is always allowed even if
                 the caller does not have permission to create tables.
                 The generated name is returned in qualified_table_name.
                 Supported values:
                 
                 The default value is FALSE.
                         COLLECTION_NAME: [DEPRECATED--please specify the
                 containing schema for the merged table as part of tableName and use GPUdb.createSchema(CreateSchemaRequest) to
                 create the schema if non-existent]  Name of a schema for
                 the newly created merged table specified by tableName.
                         IS_REPLICATED: Indicates the distribution scheme for the data of
                 the merged table specified in tableName.  If
                 true, the table will be replicated.  If false, the table will
                 be randomly sharded.
                 Supported values:
                 
                 The default value is FALSE.
                         TTL:
                 Sets the TTL of the merged table specified in
                 tableName.
                         PERSIST: If true, then the table specified in
                 tableName will be persisted and will not expire
                 unless a ttl is specified.   If false,
                 then the table will be an in-memory table and will
                 expire unless a ttl is specified otherwise.
                 Supported values:
                 
                 The default value is TRUE.
                         CHUNK_SIZE: Indicates the number of records per chunk
                 to be used for the merged table specified in tableName.
                         VIEW_ID: view this result table is part of.  The
                 default value is ''.
                 Map.public static org.apache.avro.Schema getClassSchema()
public String getTableName()
public MergeRecordsRequest setTableName(String tableName)
tableName - The name of the new result table for the records to be
                   merged into, in [schema_name.]table_name format, using
                   standard name resolution rules and meeting table naming criteria.  Must NOT be
                   an existing table.this to mimic the builder pattern.public List<String> getSourceTableNames()
public MergeRecordsRequest setSourceTableNames(List<String> sourceTableNames)
sourceTableNames - The list of names of source tables to get the
                          records from, each in [schema_name.]table_name
                          format, using standard name resolution rules.  Must
                          be existing table names.this to mimic the builder pattern.public List<Map<String,String>> getFieldMaps()
sourceTableNames being
         merged into the target table specified by tableName.
         Each mapping contains the target column names (as keys) that the
         data in the mapped source columns or column expressions (as values) will be merged into.
         All of the source columns being merged into a given target
         column must match in type, as that type will determine the type
         of the new target column.public MergeRecordsRequest setFieldMaps(List<Map<String,String>> fieldMaps)
fieldMaps - Contains a list of source/target column mappings, one
                   mapping for each source table listed in sourceTableNames being merged into the target table
                   specified by tableName.  Each mapping contains
                   the target column names (as keys) that the data in the
                   mapped source columns or column expressions (as values) will be
                   merged into.  All of the source columns being merged
                   into a given target column must match in type, as that
                   type will determine the type of the new target column.this to mimic the builder pattern.public Map<String,String> getOptions()
CREATE_TEMP_TABLE: If true, a unique temporary table
         name will be generated in the sys_temp schema and used in place
         of tableName. If persist is false, then
         this is always allowed even if the caller does not have
         permission to create tables. The generated name is returned in
         qualified_table_name.
         Supported values:
         
         The default value is FALSE.
                 COLLECTION_NAME: [DEPRECATED--please specify the containing
         schema for the merged table as part of tableName and use
         GPUdb.createSchema(CreateSchemaRequest) to
         create the schema if non-existent]  Name of a schema for the
         newly created merged table specified by tableName.
                 IS_REPLICATED: Indicates the distribution scheme for the data of the merged
         table specified in tableName.  If true, the table will
         be replicated.  If false, the table will be randomly sharded.
         Supported values:
         
         The default value is FALSE.
                 TTL: Sets
         the TTL of the merged table specified in tableName.
                 PERSIST:
         If true, then the table specified in tableName
         will be persisted and will not expire unless a ttl is
         specified.   If false, then the table will be an
         in-memory table and will expire unless a ttl is
         specified otherwise.
         Supported values:
         
         The default value is TRUE.
                 CHUNK_SIZE: Indicates the number of records per chunk to be
         used for the merged table specified in tableName.
                 VIEW_ID:
         view this result table is part of.  The default value is ''.
         Map.public MergeRecordsRequest setOptions(Map<String,String> options)
options - Optional parameters.
                 CREATE_TEMP_TABLE: If true, a unique temporary
                 table name will be generated in the sys_temp schema and
                 used in place of tableName. If persist
                 is false, then this is always allowed even if
                 the caller does not have permission to create tables.
                 The generated name is returned in qualified_table_name.
                 Supported values:
                 
                 The default value is FALSE.
                         COLLECTION_NAME: [DEPRECATED--please specify the
                 containing schema for the merged table as part of tableName and use GPUdb.createSchema(CreateSchemaRequest) to
                 create the schema if non-existent]  Name of a schema for
                 the newly created merged table specified by tableName.
                         IS_REPLICATED: Indicates the distribution scheme for the data of
                 the merged table specified in tableName.  If
                 true, the table will be replicated.  If false, the table will
                 be randomly sharded.
                 Supported values:
                 
                 The default value is FALSE.
                         TTL:
                 Sets the TTL of the merged table specified in
                 tableName.
                         PERSIST: If true, then the table specified in
                 tableName will be persisted and will not expire
                 unless a ttl is specified.   If false,
                 then the table will be an in-memory table and will
                 expire unless a ttl is specified otherwise.
                 Supported values:
                 
                 The default value is TRUE.
                         CHUNK_SIZE: Indicates the number of records per chunk
                 to be used for the merged table specified in tableName.
                         VIEW_ID: view this result table is part of.  The
                 default value is ''.
                 Map.this to mimic the builder pattern.public org.apache.avro.Schema getSchema()
getSchema in interface org.apache.avro.generic.GenericContainerpublic Object get(int index)
get in interface org.apache.avro.generic.IndexedRecordindex - the position of the field to getIndexOutOfBoundsExceptionpublic void put(int index,
                Object value)
put in interface org.apache.avro.generic.IndexedRecordindex - the position of the field to setvalue - the value to setIndexOutOfBoundsExceptionCopyright © 2024. All rights reserved.