Hive_Hive的数据模型_内部表
生活随笔
收集整理的這篇文章主要介紹了
Hive_Hive的数据模型_内部表
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
Hive的數據模型_內部表
- 與數據庫中的Table在概念上是類似。
- 每一個Table在Hive中都有一個相應的目錄存儲數據。
- 所有的Table數據(不包括External Table)都保存在這個目錄中。
?
create table t1 (tid int, tname string, age int);create table t2 (tid int, tname string, age int) location '/mytable/hive/t2'create table t3 (tid int, tname string, age int) row format delimited fields terminated by ',';create table t4 as select * from t1;?
hdfs dfs -cat /usr/hive/warehouse/tablename/000000_0?
alter table t1 add columns(english int); desc t1;?
if open the recycle bin function of hdfs . we can see the file has not been deleted, but move from one dir to another dir, we can restore it.
drop table t1;?
轉載于:https://www.cnblogs.com/liupuLearning/p/6322471.html
總結
以上是生活随笔為你收集整理的Hive_Hive的数据模型_内部表的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: php 设置中文 cookie, js获
- 下一篇: Android开发系列之屏幕密度和单位转