hbase


在cmd运行的指令

  1. list

    list all the tables

  2. !describe `*table*`

    return attributes related to the table

  3. create `*table*`, `*column family*`

    create a new table with a column family

  4. exit

    exit the shell

  5. curl – o ~/file URL

    output saved to the file with the URL

  6. head file

    gives a view of the file

  7. sed -i `1d` file

    get rid of the header row

  8. hadoop fs -copyFromLocal path path2

  9. hadoop fs -ls path2

  10. \表示下行继续

hbase *mapreduceMethod* -Dimporttsv.separator=, -Dimporttsv.columns=”
HABASE\_ROW\_KEY,
*family: column*,
*family: column*,
*family: table*” *table* hdfs://*URL*```


11. scan \`*table*\`  
returns all the rows of the table

12. put ‘*table*’, ‘*row key*’, ‘*column family: column*’, ‘*value*’  
insert a new alue or update if it already exists

13. get ‘*table*’, ‘*row key*’  
returns certain row

# 在apache phoenix运行的指令

1.  语法基本与sql类似

2.  select \* from “*table*” where “*column*” = ’*value*’ 注意单双引号

3.  !outputformat vertical  
returns in vertical format

4.  !outputformat table  
returns in default format

5.  select distinct “*column*” from “*table*”;  
returns all values without repetition

6.  upsert into “*table*” select … from “*table*”  
load the data from somewhere into the table

Author: csy99
Reprint policy: All articles in this blog are used except for special statements CC BY 4.0 reprint polocy. If reproduced, please indicate source csy99 !
评论
 Previous
polymorphism polymorphism
面向对象编程有三个特征,即封装、继承和多态。 概念封装隐藏了类的内部实现机制,从而可以在不影响使用者的前提下改变类的内部结构,同时保护了数据。 继承是为了重用父类代码,同时为实现多态性作准备。 多态是该对象自行决定响应何种行为,由方法的重写
2020-05-13
Next 
nowcode nowcode
目录排序 3 字符串 5 算法/数据结构 5 队列和栈 8 链表 11 二分搜索 15 二叉树 17 动态规划 22 位运算 25 排列组合 27 大数据 31 排序概况 名称 时间复杂度 空间复杂度 稳定排序 备注 冒泡 O(n
2020-05-10
  TOC