Forum Discussion
Anonymous
3 years agoNot applicable
Converting text into date
Hello, I have fetched ata from data source as text. In the power Query I want to conver it into a date in the first row actual date 2024-10-01 and in the second row 2024-09-01 I tried to use date....
MAwwad
3 years agoSolution Sage
The Date.FromText function expects the text date to be in a specific format.
To convert the text date in the format "2024-10-01" into a date in Power Query, you can try the following steps:
- Select the column with the text dates.
- Go to the "Transform" tab in the Power Query Editor.
- Click on the drop-down arrow next to the column header and select "Date".
- Select "Using Locale" and then choose the appropriate locale for your date format (e.g., "en-US" for "mm/dd/yyyy" or "en-GB" for "dd/mm/yyyy").
- In the "Date and Time" dialog box, select "Custom" and then enter the date format that matches the text dates in your data source (in this case, "yyyy-MM-dd").
- Click "OK" to convert the text dates to date values.
If you still encounter issues with the conversion, please provide me with more details about the error message that you are receiving, and the steps that you have followed so far.
- Anonymous3 years agoNot applicable
Thank you so much for you reply MAwwad
I could follow till step no. 4
It would be really nice if you can explain the step 5 with more details.
I am attaching current screen shot of the power query page