Hisoka-X commented on PR #41531: URL: https://github.com/apache/spark/pull/41531#issuecomment-1586081214
1. For Snowflake, I find in https://docs.snowflake.com/en/sql-reference/functions/to_binary say,  2. For MySQL, there have [--binary-as-hex](https://dev.mysql.com/doc/refman/5.7/en/mysql-command-options.html#option_mysql_binary-as-hex) to use when SQL client start. Also by my test, MySQL print hex as default ```mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3942 Server version: 8.0.33-0ubuntu0.22.04.2 (Ubuntu) Copyright (c) 2000, 2023, Oracle and/or its affiliates. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use test; Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed mysql> select 'fdsaf' as a, hex('1')as b , 'fda' as c ; +-------+------+-----+ | a | b | c | +-------+------+-----+ | fdsaf | 31 | fda | +-------+------+-----+ 1 row in set (0.00 sec) mysql> select 'fdsaf' as a, hex(1)as b , 'fda' as c ; +-------+------+-----+ | a | b | c | +-------+------+-----+ | fdsaf | 1 | fda | +-------+------+-----+ 1 row in set (0.00 sec) mysql> select 'fdsaf' as a, binary 1 as b , 'fda' as c ; +-------+------------+-----+ | a | b | c | +-------+------------+-----+ | fdsaf | 0x31 | fda | +-------+------------+-----+ 1 row in set, 1 warning (0.00 sec) mysql> select 'fdsaf' as a, binary ' ' as b , 'fda' as c ; +-------+------------+-----+ | a | b | c | +-------+------------+-----+ | fdsaf | 0x2020 | fda | +-------+------------+-----+ 1 row in set, 1 warning (0.00 sec) mysql> select 'fdsaf' as a, hex(' ') as b , 'fda' as c ; +-------+------+-----+ | a | b | c | +-------+------+-----+ | fdsaf | 2020 | fda | +-------+------+-----+ 1 row in set (0.00 sec) mysql> SELECT binary('De\\123dBeEf'); +------------------------------------------------+ | binary('De\\123dBeEf') | +------------------------------------------------+ | 0x44655C3132336442654566 | +------------------------------------------------+ 1 row in set, 1 warning (0.00 sec) ``` 3. Postgres also print hex as default https://postgresqlco.nf/doc/en/param/bytea_output/ -- 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]
