[英]How to convert Epoch to date in athena?
I have written a query to convert epoch to date conversion in Athena but the result is not expected我已经编写了一个查询以在 Athena 中将纪元转换为日期转换,但结果不是预期的
select from_unixtime(cast(epoch_values as bigint))as dates from mybdbase
result is:结果是:
dates![]() |
---|
+54113-07-13 10:11:53.000 ![]() |
+54113-07-13 10:11:57.000 ![]() |
The year is shown in the above table, How to solve this?年份如上表所示,如何解决?
use this: from_unixtime(event_timestamp/1000000)使用这个: from_unixtime(event_timestamp/1000000)
you could validate the results with this page https://www.epochconverter.com/您可以使用此页面https://www.epochconverter.com/验证结果
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.