Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

hive hbase create external table

CREATE EXTERNAL TABLE <hive_table_name>(key string,
col1 string, col2 string, col3 string
)
STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
WITH SERDEPROPERTIES ("hbase.columns.mapping" =
":key,
cf:col1,
cf:col2,
cf:col3
")
TBLPROPERTIES("hbase.table.name" = "<hbase_table_name>", "hbase.mapred.output" = "<hbase_table_name>");
 
PREVIOUS NEXT
Tagged: #hive #hbase #create #external #table
ADD COMMENT
Topic
Name
5+1 =