import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.hbase.*;
import org.apache.hadoop.hbase.client.*;
import java.io.IOException;
import org.apache.hadoop.hbase.util.Bytes;
public class ExampleForHbase
{
public static Configuration configuration;
public static Connection connection;
public static Admin admin;
public static void main(String[] args)throws IOException
{
init();
createTable("student",new String[]{"score"});
insertData("student","student1","score","English","50");
insertData("student","student1","score","Math","60");
insertData("student","student1","score","Computer","70");
insertData("student","kangyulian","score","English","80");
insertData("student","kangyulian&
Hbase编程实例代码
最新推荐文章于 2024-09-08 22:04:15 发布
本文将深入探讨HBase数据库的编程实践,通过具体的代码示例展示如何在Hadoop环境中操作和管理大数据存储。内容包括HBase的安装配置、表的创建与管理、数据的增删改查以及性能调优等关键知识点。
摘要由CSDN通过智能技术生成