Timestamp string TO epoch with milliseconds

asked 2018-10-17 17:40:00 -0600

supahcraig gravatar image

My incoming data is formatted as such: dd-MMM-yyyy HH:mm:ss.SSS. My intermediate destination is an external table in hadoop, but I need to preserve the milliseconds.

My initial thought is to simply convert that date to epoch time (in milliseconds) which would actually make using the data much easier for my particular problem. Unfortunately I can't figure out how to do that. I'm able to convert the input string field into a date, but it loses the milliseconds.

edit retag flag offensive close merge delete