Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
hi , I wanna transform my DD.MM.YYYY to DD/MM/YYYY , that it would be easier for me to link relationship with other table.
but i failed to get it , even i click Change Type to "Date " , or i use MCode to transform it , it turns error in some date.
how to success it ?
Solved! Go to Solution.
@Chanleakna123 You can simply change the column type to "Date"
But anyway here is the custom column code you need to use..
Date.FromText([DateVal] as text) as date
Proud to be a PBI Community Champion
@Chanleakna123 You can simply change the column type to "Date"
But anyway here is the custom column code you need to use..
Date.FromText([DateVal] as text) as date
Proud to be a PBI Community Champion
hi @PattemManohar still in the same issue 😞 i tried using your M code ,
while it has a lots of row , i trina clear every format.
how to settle this ? Do you have any idea ?
@Chanleakna123 Did you tried change the "Prod Date" field to Date data type.
Also, please post the same data in copiable format which will help us to replicate your issue.
Proud to be a PBI Community Champion
https://drive.google.com/file/d/10GR5mn8hpMgmmQzGSshWbjLkS83ucNzy/view?usp=sharing
you can find the link above and try it
@Chanleakna123 Imported all Date values from the file provided (There are few blank rows, which are ignored)
So total 326 rows, the same formula worked nothing changed... Working fine for me...
Proud to be a PBI Community Champion
@PattemManohar not sure why it doesn't work on my table , i change the file to excel , do a lots of thing.
OMG , 😞
@Chanleakna123 Send me the "M Code" (From "Advanced Editor") you have on the table.
Proud to be a PBI Community Champion
let
Source = Excel.Workbook(File.Contents("C:\Users\hchanleakna\Desktop\Power BI\22-Syrup Yield\Monthly Syrup Yield Reporting.xlsx"), null, true),
Sheet2_Sheet = Source{[Item="Sheet2",Kind="Sheet"]}[Data],
#"Changed Type" = Table.TransformColumnTypes(Sheet2_Sheet,{{"Column1", type text}}),
#"Promoted Headers" = Table.PromoteHeaders(#"Changed Type", [PromoteAllScalars=true]),
#"Changed Type1" = Table.TransformColumnTypes(#"Promoted Headers",{{"Date", type text}}),
#"Added Custom" = Table.AddColumn(#"Changed Type1", "Custom", each Date.FromText([Date] as text) as date)
in
#"Added Custom"
@Chanleakna123 Could you please confirm that you are using the same excel file that was shared in google drive ? As I can see only one sheet in the excel that was shared.
Proud to be a PBI Community Champion
Proud to be a PBI Community Champion
@PattemManohar hi , i changed another source of the file , and it works , thanks you so much.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
97 | |
94 | |
74 | |
71 | |
64 |
User | Count |
---|---|
143 | |
109 | |
103 | |
82 | |
74 |