hive建表初体验
use myhive;
create table stu(id int,name string);
insert into stu values (1,“zhangsan”);
select * from stu;

Hive管理表Hive管理表Hive管理表
创建表并指定字段之间的分隔符

create table if not exists stu2(id int ,name string) row format delimited fields terminated by ‘\t’ stored as textfile location ‘/user/stu2’;
Hive管理表
根据查询结果创建表

create table stu3 as select * from stu2;
Hive管理表
根据已经存在的表创建表
create table stu4 like stu2;
Hive管理表
查询表的类型
desc formatted stu2;
Hive管理表

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-07-06
  • 2021-09-01
  • 2022-12-23
  • 2021-04-20
  • 2021-08-31
猜你喜欢
  • 2021-11-08
  • 2021-07-21
  • 2021-07-21
  • 2021-04-29
  • 2021-07-22
相关资源
相似解决方案