# Parsing times with microseconds

**URL:** <https://discourse.julialang.org/t/parsing-times-with-microseconds/20366>\
**Category:** General Usage\
**Created:** [February 1, 2019, 9:20pm UTC](https://discourse.julialang.org/t/parsing-times-with-microseconds/20366 "2019-02-01T21:20:25Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![a5vzener](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/a5vzener/32/16257_2.png) [@a5vzener](https://discourse.julialang.org/u/a5vzener)\
**Post date:** [February 1, 2019, 9:20pm UTC](https://discourse.julialang.org/t/parsing-times-with-microseconds/20366/1 "2019-02-01T21:20:25Z")

</div>

I am trying to use Julia to analyze some disk I/O data. My Mac provides timestamps like 12:52:22.631949

I want to create a Time object but the extra microseconds (949) appear to cause the parser to choke.

> tf = DateFormat(“H:M:S.s”)  
> t = parse(Time,“12:52:22.631949”,tf)

InexactError: convert(Dates.Decimal3, 631949)

Looking at the source code, I see there are provisions for including Microsecond and Nanosecond in formatting, but apparently not for parsing.

My workaround has been to build a Time object manually by splitting the string, but this seems kludgy. Anyone have any suggestions how to do this cleanly?

Thanks!
