USER |
gsql("""set pcatalog.flights_lookup_cancellation_code_hbase.dataSetProperties=
{
"datasetType": "HBASE",
"fields": [
{
"fieldName": "Code",
"fieldType": "string",
"isFieldNullable": false
},
{
"fieldName": "Description",
"fieldType": "string",
"isFieldNullable": false
}
],
"partitionFields": [],
"props": {
"gimel.hbase.rowkey":"Code",
"gimel.hbase.table.name":"flights:flights_lookup_cancellation_code",
"gimel.hbase.namespace.name":"flights",
"gimel.hbase.columns.mapping":":key,flights:Description",
"datasetName":"pcatalog.flights_lookup_cancellation_code_hbase"
}
}
""")
|
HIVE |
drop table if exists pcatalog.flights_lookup_cancellation_code_hbase;
CREATE EXTERNAL TABLE `pcatalog.flights_lookup_cancellation_code_hbase`(
`Code` string,
`Description` string
)
ROW FORMAT SERDE
'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe'
STORED AS INPUTFORMAT
'org.apache.hadoop.mapred.TextInputFormat'
OUTPUTFORMAT
'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'
TBLPROPERTIES (
"gimel.hbase.rowkey"="Code",
"gimel.hbase.table.name"="flights:flights_lookup_cancellation_code",
"gimel.hbase.namespace.name"="flights",
"gimel.hbase.columns.mapping"=":key,flights:Description",
'gimel.storage.type'='HBASE');
|