[英]How to Convert Array or String in Snowflake to Timestamp_NTZ
I currently have some incoming datestamps as from outside datasource, but am struggling to define them in a table through my Snowflake Tables.我目前有一些来自外部数据源的传入日期戳,但我正在努力通过我的雪花表在表中定义它们。
The column is formatted as such: {"type":"TEXT","length":12,"byteLength":48,"nullable":true,"fixed":false}
该列的格式如下: {"type":"TEXT","length":12,"byteLength":48,"nullable":true,"fixed":false}
The only current workaround I have is this convoluted code.我目前唯一的解决方法是这个复杂的代码。
SELECT timestamp_ntz_from_parts(
GET(strtok_to_array(CONCAT('20',array_to_string(
regexp_substr_all('220530161501', '[[:digit:]][[:digit:]]', 1, 1),',')),','),0)::DOUBLE,
.......);
Any suggestions to convert string to integer for timestamp?将字符串转换为 integer 以获得时间戳的任何建议?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.