QuickSight - Transforming String into Date format

0

Hi, I have a field ("Start") in the following format: [6/17/23 9:00], currently a string. I would like to transform this into a date so that I can calculate weeks, etc., however it doesn't allow me making this a date format. I tried with edit date (see screenshot) - it doesn't seem to detect a date. Then I also tried a calculated field with parseDate function (e.g. parseDate({Start}, MM/dd/yy HH:MM), but i couldn't get it right. My data source is a csv file that I will regularly upload. Any chance someone can help me here? Thanks, Axel

已提问 1 年前2811 查看次数
2 回答
0

Instead of using calculated field to convert the date filed in visualization step ,go to datasets menu and click on the three dots at the end of the dataset name. Click Edit dataset , go to the field "Start" and right click and change the data type to 'date' with the desired format.Save the data set and refresh the dataset in the visualization tab to use it in visual.

AWS
已回答 1 年前
  • I tried this too, however, for some reason I lost all data. The data in the field is: "6/17/22 09:00" for 17th of June 9am. I tried to transform it into 'date' with adding the format: MM/dd/yyyy HH:mm. Which at least didn't end up in an error. However, now I lost all the data. Seems that I only have 7 rows left (blank) in my dataset compared to 1200 before. I made screenshots from every step (seems I'm not able to attach them though).

0

I have had issues with CSV files saved as UTF8. Try saving your CSV in an older (non UTF8) mode. I've seen some strings (with date time data) transform and others not. Seems to correlate with a day / month mismatch. Where days are less than 13 I've seen this mismatch. For days greater than 12 the transform will probably be null.

I frequently use Amazon Quicksight or Amazon Glue Databrew for configuring my data transformations. These type of data source format issues are easier to identify using this approach.

已回答 1 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则