I use something like this in perl to get the date and time:
use Time::localtime;
use Time::gmtime;
$tm = gmtime;
$time_str = sprintf "%04d-%02d-%02d %02d:%02d:%02d",
$tm->year + 1900, $tm->mon + 1, $tm->mday,
$tm->hour, $tm->min, $tm->sec;
It gives me something like this:
2010-08-26 06:50:55
I actually want the time down to the millisecond level. So I want something like:
2010-08-26 06:50:55.23
Any idea how I would get this?