I'm trying to convert a []uint8
byte slice into a float64
in GoLang. I can't find a solution for this issue online. I've seen suggestions of converting to a string first and then to a float64
but this doesn't seem to work, it loses it's value and I end up with zeroes.
Example:
metric.Value, _ = strconv.ParseFloat(string(column.Value), 64)
And it doesn't work...
strconv.ParseFloat(strings.TrimSpace(string(b)), 64)
– Hamford