Use Long.parseLong to parse the string to long.