t
t := "2016-11-02 19:23:05.503705739 +0000 UTC"

When I attempt to parse the string:

time, err := time.Parse("2016-11-02 19:18:57.149197306 +0000 UTC", t)

The result is:

0001-01-01 00:00:00 +0000 UTC

But I expected result to be:

"2016-11-02 19:18:57.149197306 +0000 UTC"

Please advise.

layoutParseMon Jan 2 15:04:05 MST 20062006-01-02 15:04:05.000000000 +0000 UTC

这篇关于将字符串转换为时间并在golang中解析的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!