bug fix for casting millisecond data