BinTaoMa opened a new issue, #11804: URL: https://github.com/apache/seatunnel/issues/11804
### Search before asking - [x] I had searched in the [issues](https://github.com/apache/seatunnel/issues?q=is%3Aissue+label%3A%22bug%22) and found no similar issues. ### What happened The DataValidator transform throws a `ClassCastException` when the `RANGE` rule validates a `DECIMAL` field against integer bounds. ### SeaTunnel Version 2.3.13 (also reproducible on the `dev` branch) ### SeaTunnel Config ```conf transform { DataValidator { plugin_input = "Jdbc" plugin_output = "DataValidator" field_rules = [ { field_name = "amount" rules = [ { rule_type = "RANGE", min_value = 0, max_value = 1000 } ] } ] } } ``` ### Running Command ```shell 1. Create a JDBC source reading a table with a `DECIMAL(10,2)` column (e.g. `amount`). 2. Add a `DataValidator` transform with a `RANGE` rule on that column using integer `min_value`/`max_value`. 3. Submit the job. The task fails at the transform step. ``` ### Error Exception ```log java.lang.ClassCastException: class java.lang.Integer cannot be cast to class java.math.BigDecimal at java.math.BigDecimal.compareTo(BigDecimal.java:305) at org.apache.seatunnel.transform.validator.rule.RangeValidationRule.validate(RangeValidationRule.java:65) at org.apache.seatunnel.transform.validator.FieldValidator.validate(FieldValidator.java:61) at org.apache.seatunnel.transform.validator.DataValidatorTransform.transformRow(DataValidatorTransform.java:103) ``` ### Zeta or Flink or Spark Version Zeta 2.3.13 ### Java or Scala Version Java 17 ### Screenshots _No response_ ### Are you willing to submit PR? - [x] Yes I am willing to submit a PR! ### Code of Conduct - [x] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
