I have a text column data which is national ID. The first 2 characters are Year, following 2 characters are Month and the next 2 characters are Day.
I have use Extract > Range in Add Column menu of Power Query to seperate out 3 columns for the first 6 digit. So I have Year, Month and Day column. Each of these column is having 2 characters in Text data type.
Next, I highlighted these 3 columns and right click to select Merge Columns, seperator is / . The output is like this
Then, I change the data type to Date data type. However, it comes out with Error.
How to solve this errror?
This works.
Hi,
I think your setting is mm/dd/yyyy, but you want dd/mm/yyyy. (Or, other way round)
Please try the below.
-Place the cursor on the column name [Dates]
-Right click
-select "Change Type" -> "Using Locale"
-select "Data Type" = "Date"
-select "Locale" = English (United Kingdom) or your setting.
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
@alvin199 , append as year-month-date
or create a new column like - Power query
#date([Year],[Months], [Days])
Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!
User | Count |
---|---|
102 | |
79 | |
71 | |
48 | |
47 |
User | Count |
---|---|
157 | |
89 | |
81 | |
69 | |
67 |