URL: http://GPUDB_IP_ADDRESS:GPUDB_PORT/create/union
Creates a table that is the concatenation of one or more existing tables. It is equivalent to the SQL UNION ALL operator. Non-charN 'string' and 'bytes' column types cannot be included in a union, neither can columns with the property 'store_only'.
Input Parameter Description
Name | Type | Description | ||||
---|---|---|---|---|---|---|
table_name | string | Name of the table to be created. Must not be the name of a currently existing GPUdb table. Cannot be an empty string. | ||||
table_names | array of strings | The list of table names making up the union. Must contain the names of one or more existing tables. | ||||
input_column_names | array of arrays of strings | The list of columns from each of the corresponding input tables. | ||||
output_column_names | array of strings | The list of names of the columns to be stored in the union. | ||||
options | map of strings | Optional parameters. Default value is an empty map ( {} ).
|
Output Parameter Description
The GPUdb server embeds the endpoint response inside a standard response structure which contains status information and the actual response to the query. Here is a description of the various fields of the wrapper:
Name | Type | Description | ||||||
---|---|---|---|---|---|---|---|---|
status | String | 'OK' or 'ERROR' | ||||||
message | String | Empty if success or an error message | ||||||
data_type | String | 'create_union_request' or 'none' in case of an error | ||||||
data | String | Empty string | ||||||
data_str | JSON or String | This embedded JSON represents the result of the /create/union endpoint:
Empty string in case of an error. |