Skip to content
Permalink
Browse files
Clarifying limitations and updating syntax for "hawq register". This c…
…loses #58

Update restrictions

Signed-off-by: David Yozie <yozie@apache.org>

Update hawq register syntax for consistency

Signed-off-by: David Yozie <yozie@apache.org>
  • Loading branch information
janebeckman authored and dyozie committed Nov 14, 2016
1 parent fdd6b09 commit dc9869600c9757e404609372c05049e45c5f8c20
Showing 2 changed files with 17 additions and 11 deletions.
@@ -85,6 +85,9 @@ Tables using random distribution are preferred for registering into HAWQ.

There are additional restrictions when registering hash tables. When registering hash-distributed tables using a YAML file, the distribution policy in the YAML file must match that of the table being registered into and the order of the files in the YAML file should reflect the hash distribution. The size of the registered file should be identical to or a multiple of the hash table bucket number.

Only single-level partitioned tables can be registered into HAWQ.


###Example: Registration using a YAML Configuration File

This example shows how to use `hawq register` to register HDFS data using a YAML configuration file generated by hawq extract.
@@ -11,19 +11,19 @@ Usage 1:
hawq register [<connection_options>] [-f <hdfsfilepath>] [-e <Eof>] <tablename>

Usage 2:
hawq register [<connection_options>] [-c <configfilepath>][--force] <tablename>
hawq register [<connection_options>] [-c <configfilepath>][-F] <tablename>

Connection Options:
[-h <hostname>]
[-p <port>]
[-U <username>]
[-d <database>]
[-h | --host <hostname>]
[-p | --port <port>]
[-U | --user <username>]
[-d | --database <database>]

Misc. Options:
[-f <filepath>]
[-e <eof>]
[--force]
[-c <yml_config>]
[-f | --filepath <filepath>]
[-e | --eof<eof>]
[-F | --force ]
[-c | --config <yml_config>]
hawq register help | -?
hawq register --version
```
@@ -55,8 +55,9 @@ Two usage models are available.
Metadata for the Parquet file(s) and the destination table must be consistent. Different data types are used by HAWQ tables and Parquet files, so the data is mapped. Refer to the section [Data Type Mapping](hawqregister.html#topic1__section7) below. You must verify that the structure of the Parquet files and the HAWQ table are compatible before running `hawq register`.

####Limitations
Only HAWQ or Hive-generated Parquet tables are supported. Partitioned tables are supported, but only single-level partitioned tables can be registered into HAWQ.
Hash tables are not supported in this use model.

Only HAWQ or Hive-generated Parquet tables are supported.
Hash tables and partitioned tables are not supported in this use model.

###Usage Model 2: Use information from a YAML configuration file to register data

@@ -76,6 +77,8 @@ The currently-supported data types for generating Hive tables into HAWQ tables a

The following HIVE data types cannot be converted to HAWQ equivalents: timestamp, decimal, array, struct, map, and union.

Only single-level partitioned tables are supported.

###Data Type Mapping<a id="topic1__section7"></a>

HAWQ and Parquet tables and HIVE and HAWQ tables use different data types. Mapping must be used for compatibility. You are responsible for making sure your implementation is mapped to the appropriate data type before running `hawq register`. The tables below show equivalent data types, if available.

0 comments on commit dc98696

Please sign in to comment.