BINARY
Warning
SingleStore 9.0 gives you the opportunity to preview, evaluate, and provide feedback on new and upcoming features prior to their general availability. In the interim, SingleStore 8.9 is recommended for production workloads, which can later be upgraded to SingleStore 9.0.
On this page
Casts the input to a binary data type.
There is usually no visible effect on the printed value; what changes is the rules for comparison and sorting.
Syntax
BINARY( input )
Return Type
A binary object.
Examples
SELECT 'ohai' = 'OHAI', BINARY('ohai') = 'OHAI';
+-----------------+-------------------------+
| 'ohai' = 'OHAI' | BINARY('ohai') = 'OHAI' |
+-----------------+-------------------------+
| 1 | 0 |
+-----------------+-------------------------+
Last modified: March 8, 2024