Skip to main content

XOR

Descriptionโ€‹

Return the XOR value of two numbers.

Syntaxโ€‹

BOOLEAN xor BOOLEAN

Exampleโ€‹

mysql> select true xor false, true xor true;
+------------------+-----------------+
| (TRUE XOR FALSE) | (TRUE XOR TRUE) |
+------------------+-----------------+
| 1 | 0 |
+------------------+-----------------+

Keywordsโ€‹

XOR

Enter to send ยท Shift+Enter for a new line