Hive(数据库相关)

Hive
hive的交互方式:
第一种交互方式
cd /export/servers/apache-hive-2.1.1-bin/
bin/hive

创建一个数据库
create database if not exists mytest

第二种交互方式:使用sql语句或者sql脚本进行交互
不进入hive的客户端直接执行hive的hql语句
cd /export/servers/apache-hive-2.1.1-bin
bin/hive -e 'create database if not exists mytest;'

或者我们将我们的hql语句写成一个sql脚本然后执行
cd /export/servers
vim hive.sql

create database if not exists mytest;
use mytest
create table stu(id int,

Hive(数据库相关)最先出现在Python成神之路

版权声明:
作者:ht
链接:https://www.techfm.club/p/4190.html
来源:TechFM
文章版权归作者所有,未经允许请勿转载。

THE END
分享
二维码
< <上一篇
下一篇>>