使用Hbase配置Hive [英] Configuring Hive with Hbase

查看:107
本文介绍了使用Hbase配置Hive的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要使用配置单元在HBase上执行查询。我已经下载了HBase并配置了我的HMaster,运行良好;我需要知道我需要为配置单元使用HBase作为后端数据库进行哪些配置更改。任何链接教程将不胜感激。
在此先感谢。

I need to execute queries on HBase using hive. I have downloaded the HBase and hive my HMaster is running fine; I need to know what configuration changes I need to do for hive to work with HBase as the back end database. Any link tutorial will be appreciated. Thanks in advance.

推荐答案

apache Hive wiki很好地解释了它 https://cwiki.apache.org/confluence/display/Hive/HBaseIntegration

The apache Hive wiki explains it nicely https://cwiki.apache.org/confluence/display/Hive/HBaseIntegration

创建一个由hive管理的HBase表,可以尝试类似于

To create an HBase table that is managed from hive try something like

CREATE TABLE hive_managed(key string, value1 string, value2 int)
STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
WITH SERDEPROPERTIES ("hbase.columns.mapping" = ":key,columnFamilyName:val1,columnFamilyName:val2")
TBLPROPERTIES ("hbase.table.name" = "hivemanaged");

*编辑下面的评论

这篇关于使用Hbase配置Hive的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆