weizuo93 opened a new issue #7510: URL: https://github.com/apache/incubator-doris/issues/7510
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/incubator-doris/issues?q=is%3Aissue) and found no similar issues. ### Version master branch. (commit id : 6e052f4ede6beea1d561113f24252c32fc7fc743) ### What's Wrong? The return value type of the function `percentile_approx` would be parsed as double type. When `nan` value returned by function `percentile_approx`, the return value can not be parsed as double by JDBC and the exception `Bad format for number 'nan' in column ...` will be thrown by JDBC. The stack is shown as following: ``` java.sql.SQLException: Bad format for number 'nan' in column 1. at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:898) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:887) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:861) at com.mysql.jdbc.ResultSetImpl.getDoubleInternal(ResultSetImpl.java:2324) at com.mysql.jdbc.ResultSetImpl.getDoubleInternal(ResultSetImpl.java:2264) at com.mysql.jdbc.ResultSetImpl.getDouble(ResultSetImpl.java:2232) at com.mysql.jdbc.ResultSetImpl.getObject(ResultSetImpl.java:4506) at org.example.JdbcService.nanTest(JdbcService.java:93) ``` ### What You Expected? The return value can be parsed by JDBC successfully. ### How to Reproduce? _No response_ ### Anything Else? _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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
