prestodb/presto · error · PrestoException
NOT_SUPPORTED
NOT_SUPPORTED
Error message
Unsupported type
What it means
Row.valueFromString converts a String token into a Java value for the given Presto Type; when the schema column's type has no conversion branch it throws NOT_SUPPORTED with 'Unsupported type <type>'. It is invoked per-field by Row.fromString, so one unsupported column type fails the whole row parse.
Source
Thrown at presto-accumulo/src/main/java/com/facebook/presto/accumulo/model/Row.java:235
return Short.parseShort(str);
}
else if (type.equals(TIME)) {
return Time.valueOf(LocalTime.parse(str, TIME_PARSER));
}
else if (type.equals(TIMESTAMP)) {
return Timestamp.valueOf(LocalDateTime.parse(str, TIMESTAMP_PARSER));
}
else if (type.equals(TINYINT)) {
return Byte.valueOf(str);
}
else if (type.equals(VARBINARY)) {
return str.getBytes(UTF_8);
}
else if (type instanceof VarcharType) {
return str;
}
else {
throw new PrestoException(NOT_SUPPORTED, "Unsupported type " + type);
}
}
}
View on GitHub (pinned to 55bb57d202)
Solutions
- Remove or exclude the unsupported column from the RowSchema being deserialized
- Cast the column type in metadata to a supported type (e.g. cast array to VARCHAR before storage)
- Add a conversion branch in valueFromString for the type (fork/maintenance path)
- Use LexicoderRowSerializer instead of String-based deserialization, since it supports complex types
Example fix
// before
else {
throw new PrestoException(NOT_SUPPORTED, "Unsupported type " + type);
}
// after
else if (type instanceof DecimalType) {
return new BigDecimal(str);
} else {
throw new PrestoException(NOT_SUPPORTED, "Unsupported type " + type);
} Defensive patterns
Strategy: validation
Validate before calling
for (int i = 0; i < schema.getLength(); i++) {
Type t = schema.getColumn(i).getType();
if (!(t instanceof VarcharType) && !SUPPORTED_ROW_TYPES.contains(t)) {
throw new IllegalArgumentException("Column " + schema.getColumn(i).getName() + " has unsupported type " + t);
}
} Type guard
static boolean isRowDecodableType(Type t) {
return t instanceof VarcharType || t.equals(BOOLEAN) || t.equals(BIGINT) || t.equals(DOUBLE) || t.equals(REAL) || t.equals(DATE) || t.equals(TIME) || t.equals(TIMESTAMP);
} Try / catch
try {
value = Row.valueFromString(token, type);
} catch (PrestoException e) {
if (e.getErrorCode().getCode() == StandardErrorCode.NOT_SUPPORTED.toErrorCode().getCode()) {
return null; // or log and skip column
}
throw e;
} Prevention
- Verify all schema column types are supported before deserializing records
- Exclude complex types (ARRAY/MAP/ROW/DECIMAL) from string-based row schemas
- Use LexicoderRowSerializer for schemas with complex types
- Add unit tests covering every column type in the schema
When it happens
Trigger: Row.fromString / valueFromString with a schema column whose Type is not among the handled ones (BOOLEAN, BIGINT/integer family, DOUBLE, REAL, VARCHAR, VARBINARY, DATE/TIME/TIMESTAMP family, etc.), e.g. arrays, maps, rows, DECIMAL, JSON, hyperloglog.
Common situations: Connector schema includes ARRAY/MAP columns but the record format is plain delimited strings; newer Presto types added to the table schema that the deserializer predates.
Understand the failure class
Background: Presto NOT_SUPPORTED error: what "not supported" means and how to fix it — this error's family across 3 libraries.
Related errors
AI-assisted analysis of prestodb/presto@55bb57d202 (2026-09-04).
Data as JSON: /api/errors/bdbb6dc2897f941f.
Report an issue: GitHub.