[Tutor] Support for datetime module
kent37 at tds.net
Sun Sep 7 13:04:07 CEST 2008
On Sun, Sep 7, 2008 at 6:17 AM, Johan Geldenhuys <johan at accesstel.com.au> wrote:
> Thanks Kent,
> Let me explain what I need it for.
> I have a systemUpTime is seconds that I got from a SNMP agent.
> I want to work out when the system uptime began and want to put that in ISO
> format time to the millisecond.
> So my idea is to take a timestamp in seconds when I get the systemUpTime. I
> subtract the uptime from my timestamp and then format that into ISO format.
> That should give me a fairly accurate UTC-like time of when the systemUpTime
> Here is an example: "2008-09-04 22:29:43.221 Z"
I think you can do all that with functions in the time module.
More information about the Tutor