30. Hive 语句
QUERIES
SELECT …. FROM …..WHERE……
GROUP BY….ORDER BY….LIMIT
JOIN
DDL
database 、 table(location 、 Partitions)
funciton 、 index 、 view
DML
Loading files into tables
Inserting data into Hive Tables from queries
Writing data into filesystem from queries
31. Hive 改进
Not support Multi-distinct
bash:
cat t_mall_buy.txt | awk ‘{print uid}’ | sort | uniq | wc –l
cat t_mall_buy.txt | awk ‘{print urs}’ | sort | uniq | wc –l
mysql :
SELECT count(distinct uid), count(distint urs)
FROM t_mall_buy
hive:
SELECT count(distinct uid) FROM t_mall_buy
SELECT count(distinct urs) FROM t_mall_buy
补丁支持
https://issues.apache.org/jira/browse/HIVE-287
https://issues.apache.org/jira/browse/HIVE-474
32. Hive 改进
不支持 exists in 子查询
support NOT IN and NOT LIKE syntax in version 0.8
Not support Index
Not available until 0.7 release
Not support Insert into
INSERT INTO syntax is only available starting in version
0.8