-
cast 强制类型转换
cast(info as BIGINT)
-
concat_ws 字符串的链接
concat_ws('-',year,month,day)
-
split 字符串的分割
split(info,',')
-
lateral view explode 字符串的延展
lateral view explode(split(param['info'],'\;')) snTable as split_info
-
unix_timestamp 日期转毫秒
(unix_timestamp(start_time)-unix_timestamp(end_time))/60 (分钟)
-
case
case when a>1 then 1 when a>=1 and a<2 then 2 else 3 end as tmp
-
from_unixtime 毫秒转日期
from_unixtime(1511022000,'yyyy-MM-dd HH:mm:ss')
-
select 未命名的列 _c0
select sum(
_c0) from table
-
得到行号 row_umber()
select name, row_umber() over() from stu_table;
-
展示一个表创建时候的信息
show create table student_talbe;
-
查看一个表的所有的字段名
show full columns from question
网友评论