hozan23 opened a new issue, #26887:
URL: https://github.com/apache/datafusion/issues/26887

   ### Describe the bug
   
   Follow-up to #26882. `arrow_dtype_to_ast_dtype` hard-codes the cast types 
for `Int16` and the unsigned integers, so `MySqlDialect` cannot override them:
   
     | Arrow type | Unparsed as |
     |---|---|
     | `Int16` | `SMALLINT` |
     | `UInt8` | `TINYINT UNSIGNED` |
     | `UInt16` | `SMALLINT UNSIGNED` |
     | `UInt32` | `INTEGER UNSIGNED` |
     | `UInt64` | `BIGINT UNSIGNED` |
   
     MySQL's `CAST` accepts none of these (see the [permitted 
types](https://dev.mysql.com/doc/refman/8.0/en/cast-functions.html#function_cast)),
 so the generated SQL fails with `ERROR 1064`.
   
   
   ### To Reproduce
   
   _No response_
   
   ### Expected behavior
   
   _No response_
   
   ### Additional context
   
   _No response_
   
   ### Willingness to contribute
   
   I plan to contribute a fix for this bug independently


-- 
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]

Reply via email to