Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Sign up nowGet Fabric certified for FREE! Don't miss your chance! Learn more
Hi guys, I have the following question. It is probably very trivial but I want to know how to make a date from "1022020" in pbi = "01.02.2020". Thank you very much! Abba
Solved! Go to Solution.
Alright, you should be able to follow the following steps:
Starting table with two dates:
Add this custom column to make all dates 8 digit:
Column = if Text.Length([Date]) = 8 then [Date] else "0" & [Date]
Giving the following result:
Finally we add the last column to convert it to the correct format:
Column 2 = Text.Start([Column] , 2) & "." &
Text.Range([Column] , 2 , 2) & "." &
Text.End([Column] , 4)
Giving the following result:
Which you can simply convert to date:
Br,
J
Hi @Anonymous ,
If what you want is to display the date as ‘01.02.2020’, unfortunately, the current version of Power BI(October 2020) does not support this format.
Best regards,
Lionel Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Do you want the date to remain a string/text value or do you also want it converted to datetype?
In Power Query you can use the following column:
Column =
Text.Start([Column] , 2) & "." &
Text.Range([Column] , 2 , 2) & "." &
Text.End([Column] , 4)
In Dax you can use the following:
Column = LEFT('Table'[Column] , 2) & "." & RIGHT(LEFT('Table'[Column] , 4) , 2) & "." & RIGHT('Table'[Column] , 4)
Let me know how it goes.
/ J
I want tp convert it to a date datatype.
Alright, you should be able to follow the following steps:
Starting table with two dates:
Add this custom column to make all dates 8 digit:
Column = if Text.Length([Date]) = 8 then [Date] else "0" & [Date]
Giving the following result:
Finally we add the last column to convert it to the correct format:
Column 2 = Text.Start([Column] , 2) & "." &
Text.Range([Column] , 2 , 2) & "." &
Text.End([Column] , 4)
Giving the following result:
Which you can simply convert to date:
Br,
J
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 63 | |
| 62 | |
| 42 | |
| 19 | |
| 16 |
| User | Count |
|---|---|
| 118 | |
| 106 | |
| 38 | |
| 28 | |
| 27 |