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

asked a year ago2741 views
2 Answers
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
answered a year ago
  • 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.

answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions