Reply
Member
Posts: 142
Registered: ‎01-10-2016
Accepted Solution

how to change text to date

Hi,

 

I have data coming from SalesForce. BI is not recognising the date as date. when changing the type to date, am left with so many errors, which is quite strange, as the date in the error tab is still formatted in the same way of the correct ones.

 

Power Bi.PNGpower bi1.PNG

 

I tried few methods that I know, but none worked. I changed the value of / with none and then tried to workout the CALCULATING the Infraction Date but it didn't perform as expected due to the number of characters are not equal in all rows.

 

powerbi3.PNG

 

 

Any thoughts to help in a solution? 

 


Accepted Solutions
Highlighted
Established Member
Posts: 192
Registered: ‎01-08-2016

Re: how to change text to date

Looks like you're parsing a "DD/MM/YYYY" format, but your workbook's culture is "MM/DD/YYYY". Luckily, Date.FromText takes an optional culture parameter. Can you try Date.FromText([CreateDate], "en-GB") ?

View solution in original post


All Replies
Highlighted
Established Member
Posts: 192
Registered: ‎01-08-2016

Re: how to change text to date

Looks like you're parsing a "DD/MM/YYYY" format, but your workbook's culture is "MM/DD/YYYY". Luckily, Date.FromText takes an optional culture parameter. Can you try Date.FromText([CreateDate], "en-GB") ?

Member
Posts: 142
Registered: ‎01-10-2016

Re: how to change text to date

It indeed has worked @arify 

 

Thanks mate

Member
Posts: 46
Registered: ‎02-04-2016

Re: how to change text to date

Great!  Worked for me as well