
hive
mengzhongjack
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
SparkSQL 技巧 - cache table 缓存 和 stack生成列
–缓存性别表,表名sex,字段名sex,有2行cache table sex_table asselect stack(2,‘M’,‘F’) as sex;–缓存缴费期表,表名ppp_table,字段名ppp,有4行cache table ppp_table asselect stack(4,10,15,20,30) as ppp;–生成一个1~200的顺序表。因为接下来的连续的投保年龄,和连续的保单年度,都不会超过200,所以200已经够用。cache table seq_table as原创 2022-04-13 23:36:53 · 2261 阅读 · 0 评论 -
利用 repeat 和 posexplode 函数生成日期小时等时间序列表
利用 repeat 和 posexplode 函数生成日期小时等时间序列表drop table if exists qt_report.temp_d_c_001;create table qt_report.temp_d_c_001select date_add(start_date_,st_index) as date_ from ( select start_date_ ,end_date_ ,原创 2022-03-28 19:10:10 · 414 阅读 · 0 评论