简体   繁体   中英

How do I convert milliseconds into DateTime in Power Bi?

I have a table that has 13 digit timestamps (milliseconds I believe) but I can't convert them in Power Bi for some reason. I've looked at many methods online and it should work but I keep getting an error each time I try to convert. (This is from transform data and after adding a custom column)

在此处输入图像描述

When I try to convert the timestamps in "created" column into a new custom column I get an error. This is the formulae I use when creating a new column.

#datetime(1970, 1, 1, 0, 0, 0) + #duration(0, 0, 0, [Created]/1000)

This apparently works for other people who have the same problem but not for me and I'm not sure why that is, I just keep getting Errors.

Any help would be appreciated.

The problem is likely that your [Created] column is formatted as text.

Try converting that column to a numerical type before writing a custom column that tries to divide by 1000.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM