Search code examples
powerbipowerquerypowerbi-desktopdata-cleaningm

PowerBI/Power Query - Convert Unix Time to PQ DateTime


Using PowerBI, I want to convert whole number values (eg. 1665158288, 1665159555, etc) to datetime.

I have tried the following approach the date_output is whole number formatted, but encounter errors.

date_output = DateTime.From([upLoad_date] * 86400)


Each cell has errors such as below. 

DataFormat.Error: We couldn't convert to DateTime. Details: 1.4387E+14


Solution

  • #datetime(1970,1,1,0,0,0)+ #duration(0,0,0,[Unix])
    

    enter image description here

    enter image description here