2
我在使用Amazon Athena服務格式化時間戳時遇到了一些問題。AWS Athena和date_format
select date_format(current_timestamp, 'y')
僅返回 'Y'(串)。
我發現格式的日期在亞馬遜雅典娜的唯一途徑是低谷CONCAT
+ YEAR
+ MONTH
+ DAY
功能,像這樣:
select CONCAT(cast(year(current_timestamp) as varchar), '_', cast(day(current_timestamp) as varchar))
它不是cle你需要的結果是什麼?請添加數據示例。 –