Transforming the timestamp into milliseconds