From 904fbb6221cf2009f81264986d117bef8696c12c Mon Sep 17 00:00:00 2001 From: Ryan Liang Date: Fri, 12 Apr 2024 14:13:37 -0700 Subject: [PATCH] Correct the parsing of timestamp Signed-off-by: Ryan Liang --- .../__data__/repository/aws_s3/assets/create_mv-1.0.0.sql | 1 + 1 file changed, 1 insertion(+) diff --git a/server/adaptors/integrations/__data__/repository/aws_s3/assets/create_mv-1.0.0.sql b/server/adaptors/integrations/__data__/repository/aws_s3/assets/create_mv-1.0.0.sql index 9c16cc7d1a..f234730f96 100644 --- a/server/adaptors/integrations/__data__/repository/aws_s3/assets/create_mv-1.0.0.sql +++ b/server/adaptors/integrations/__data__/repository/aws_s3/assets/create_mv-1.0.0.sql @@ -2,6 +2,7 @@ CREATE MATERIALIZED VIEW {table_name}_mview AS SELECT owner_id AS `aws.s3.bucket_owner`, bucket_name AS `aws.s3.bucket`, + to_timestamp(CONCAT(SUBSTRING(request_time, 2), ' ', SUBSTRING(request_time_zone, 1, LENGTH(request_time_zone) - 1)), 'dd/MMM/yyyy:HH:mm:ss Z') AS `@timestamp`, CONCAT(request_time, ' ', request_time_zone) AS `aws.s3.request_time`, remote_ip AS `aws.s3.remote_ip`, requester AS `aws.s3.requester`,