Forum Discussion

bourne2000's avatar
bourne2000
Helper V
5 years ago
Solved

Getting DataFormat.Error: We couldn't convert to Number.

Hi   I am having two dates such as hire date and terminated date. I am trying to merge these two dates into my calendar table for my analysis. I am using below M Query to create an additional colum...
  • v-deddai1-msft's avatar
    5 years ago

    Hi bourne2000 ,

     

    What's the regional settings in your pbix file?

     

    Or try to convert it to "en-US" format:

     

    = Table.TransformColumnTypes(your last step, {{"datecolumnname", type date}}, "es-US")

     

    Then use the 

    {Number.From([Hire Date])..Number.From([Terminated date])}

     

    It will works as your expection.

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

    Best Regards,

    Dedmon Dai