apache/flink · error · IllegalArgumentException

A predicate on a DECIMAL column requires a BigDecimal litera

Error message

A predicate on a DECIMAL column requires a BigDecimal literal.

What it means

Error "A predicate on a DECIMAL column requires a BigDecimal literal." thrown in apache/flink.

Source

Thrown at flink-formats/flink-orc/src/main/java/org/apache/flink/orc/OrcFilters.java:474

                case DATE:
                    if (literal instanceof Date) {
                        return literal;
                    } else {
                        throw new IllegalArgumentException(
                                "A predicate on a DATE column requires a java.sql.Date literal.");
                    }
                case TIMESTAMP:
                    if (literal instanceof Timestamp) {
                        return literal;
                    } else {
                        throw new IllegalArgumentException(
                                "A predicate on a TIMESTAMP column requires a java.sql.Timestamp literal.");
                    }
                case DECIMAL:
                    if (literal instanceof BigDecimal) {
                        return new HiveDecimalWritable(HiveDecimal.create((BigDecimal) literal));
                    } else {
                        throw new IllegalArgumentException(
                                "A predicate on a DECIMAL column requires a BigDecimal literal.");
                    }
                default:
                    throw new IllegalArgumentException("Unknown literal type " + literalType);
            }
        }
    }

    abstract static class BinaryPredicate extends ColumnPredicate {
        final Serializable literal;

        BinaryPredicate(String columnName, PredicateLeaf.Type literalType, Serializable literal) {
            super(columnName, literalType);
            this.literal = literal;
        }
    }

    /** An EQUALS predicate that can be evaluated by the OrcInputFormat. */

View on GitHub (pinned to 2f3c205e92)

Solutions

  1. Address the cause reported by the error message: A predicate on a DECIMAL column requires a BigDecimal literal.
  2. Verify the inputs, configuration values, and classpath/dependency setup related to this operation, then retry.

Example fix

Correct the condition described ("A predicate on a DECIMAL column requires a BigDecimal literal.") and rerun the job or command.

When it happens

Trigger: Triggered at runtime when the operation fails because: A predicate on a DECIMAL column requires a BigDecimal literal.

Common situations: Commonly caused by misconfiguration, missing dependencies or files, unsupported types or operations, or invalid user input leading to: A predicate on a DECIMAL column requires a BigDecimal literal.


AI-assisted analysis of apache/flink@2f3c205e92 (2026-08-14). Data as JSON: /api/errors/da93712a846d3233. Report an issue: GitHub.