当前位置:网站首页>How sparksql returns a specific day of the week by date -dayofweek function
How sparksql returns a specific day of the week by date -dayofweek function
2022-06-26 17:21:00 【Big data Xiao Wang】
dayofweek Function returns the workday index value of the date , That is, Sunday is 1, Monday 2, Think of six for 7
And how to turn the common Monday into 1, Zhou Erwei 2, Wednesday is 3,... Zhou 6 position 6, Sunday is 7
select if((dayofweek('2022-06-23')-1)%7=0,7,(dayofweek('2022-06-23')-1)%7);
select dayofweek('2022-06-23')
边栏推荐
- Count the number of each vowel letter in the string
- SQL injection for Web Security (3)
- Leetcode topic [array] -283- move zero
- 玩轉Linux,輕松安裝配置MySQL
- Leetcode HOT100 (22--- bracket generation)
- Teach you to learn dapr - 5 Status management
- 有依赖的背包问题
- Toupper function
- VSCode使用 - Remote-SSH 配置说明
- Technical scheme design of chain game system development - NFT chain game system development process and source code
猜你喜欢
Cache breakdown! Don't even know how to write code???
NFT 交易市场社区所有化势不可挡
14《MySQL 教程》INSERT 插入数据
Romance of the Three Kingdoms: responsibility chain model
Teach you to learn dapr - 8 binding
Can Luo Yonghao succeed in entering the AR field this time?
Kubernetes essential tools: 2021
Leetcode 1170. Frequency of occurrence of the minimum letter of the comparison string (yes, solved)
The latest masterpiece of Alibaba, which took 182 days to produce 1015 pages of distributed full stack manual, is so delicious
Inspirational. In one year, from Xiaobai to entering the core Department of Alibaba, his counter attack
随机推荐
Environment setup mongodb
sql中ROUND和TRUNCATE的区别(四舍五入还是截取小数点后几位)
Can Luo Yonghao succeed in entering the AR field this time?
物联网协议的王者:MQTT
Incomplete line spacing adjustment of formula display in word
The latest masterpiece of Alibaba, which took 182 days to produce 1015 pages of distributed full stack manual, is so delicious
Calculate the average of N numbers in the group indexed by the formal parameter x, move the data less than the average in the group indexed to the front of the array, and move the data greater than or
Turtle cartography
链游系统开发技术方案设计丨NFT链游系统开发流程及源码
Treasure and niche CTA animation material website sharing
有依赖的背包问题
Teach you to learn dapr - 6 Publish subscription
Calculate a=1, a2=1/1=a1
关于FlowUs这一款国民好笔记
Problems encountered this week
Technical scheme design of chain game system development - NFT chain game system development process and source code
Web3去中心化存储生态图景
Comp281 explanation
Discover K8E: minimalist kubernetes distribution
Romance of the Three Kingdoms: responsibility chain model