presto-record-decoder/src/main/java/io/prestosql/decoder/json/DefaultJsonFieldDecoder.java/DefaultJsonFieldDecoder/getLong
class DefaultJsonFieldDecoder:        @Override
        public long getLong()
        {
            try {
                long longValue;
                if (value.isIntegralNumber() && !value.isBigInteger()) {
                    longValue = value.longValue();
                    if (longValue >= minValue && longValue <= maxValue) {
                        return longValue;
                    }
                }
                else if (value.isValueNode()) {
                    longValue = parseLong(value.asText());
                    if (longValue >= minValue && longValue <= maxValue) {
                        return longValue;
                    }
                }
            }
            catch (NumberFormatException ignore) {
                // ignore
            }
            throw new PrestoException(
                    DECODER_CONVERSION_NOT_SUPPORTED,
                    format("could not parse value '%s' as '%s' for column '%s'", value.asText(), columnHandle.getType(), columnHandle.getName()));
        }