unix-time

What time format is this? (not UNIX, not UTC, nothing)

I'm importing data from another system to MySQL, its a CSV file. The "Date" field however contains cryptic of 3-digit time entries, here's a random sample set: > 540 > 780 > 620 > 965 What's this? obviously its not 5:40 and 6:20. But it's not UNIX either (I tried 1225295**XXX** before I realized the time range this represents is about...

Midnight in UTC time zone with unix timestamp

I was looking for a numeric representation for a date and unix time for midnight (in UTC) seems to be reasonable choice for that. However, as I'm not sure in my math skills, so is date = date - date % (24 * 60 * 60); where date is unix timestamp, the way to do that? Is there any simpler method? ...

How to specify time zone (UTC) when converting to Unix time? (Python)

I have a utc timestamp in the IS8601 format and am trying to convert it to unix time. This is my console session: In [9]: mydate Out[9]: '2009-07-17T01:21:00.000Z' In [10]: parseddate = iso8601.parse_date(mydate) In [14]: ti = time.mktime(parseddate.timetuple()) In [25]: datetime.datetime.utcfromtimestamp(ti) Out[25]: datetime.datetim...

Python Unix time doesn't work in Javascript

In Python, using calendar.timegm(), I get a 10 digit result for a unix timestamp. When I put this into Javscript's setTime() function, it comes up with a date in 1970. It evidently needs a unix timestamp that is 13 digits long. How can this happen? Are they both counting from the same date? How can I use the same unix timestamp between...