回覆列表
  • 1 # 愛吃路邊攤55658

    HBASE中的表示按column family來儲存的 建立一個有3個column family的表 create "t1", {NAME => "f1", VERSIONS => 1}, {NAME => "f2", VERSIONS => 1}, {NAME => "f3", VERSIONS => 1} 定義表的時候只需要指定column family的名字,列名在put的時候動態指定 插入資料 下面插入沒有指定column的名字 put "t1", "r1", "f1", "v1" put "t1", "r2", "f2", "v2" put "t1", "r3", "f3", "v3" 下面插入指定column的名字 put "t1", "r4", "f1:c1", "v1" put "t1", "r5", "f2:c2", "v2" put "t1", "r6", "f3:c3", "v3" hbase(main):245:0> scan "t1" ROW COLUMN+CELL r1 column=f1:, timestamp=1335407967324, value=v1 r2 column=f2:, timestamp=1335408004559, value=v2 r4 column=f1:c1, timestamp=1335408640777, value=v1 r5 column=f2:c1, timestamp=1335408640822, value=v2 r6 column=f1:c6, timestamp=1335412392258, value=v3 r6 column=f2

  • 中秋節和大豐收的關聯?
  • win7用ie瀏覽器好個版本好用?