【presto 日期处理】
上篇文章【hive 日期处理】中我们介绍了hive的日期使用方法,现在我们对比看一下presto要如何实现1、返回当周的周一select date_format(date_trunc('week',current_date),'%Y-%m-%d')2、返回当周周五select date_add('day',4,cast(date_format(date_trunc('week',current_date),'%Y-%m-%d') as date))3、日期加减(日、小时、分钟、秒)sele
原创
2022-01-12 16:51:04 ·
5929 阅读 ·
0 评论