Bit operation
mysql>
mysql> CREATE TABLE MATCHES
-> (MATCHNO INTEGER NOT NULL,
-> TEAMNO INTEGER NOT NULL,
-> EmployeeNO INTEGER NOT NULL,
-> WON SMALLINT NOT NULL,
-> LOST SMALLINT NOT NULL,
-> PRIMARY KEY (MATCHNO) );
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql> SELECT MATCHNO, TEAMNO, MATCHNO | TEAMNO,
-> MATCHNO & TEAMNO, MATCHNO ^ TEAMNO
-> FROM MATCHES;
Empty set (0.00 sec)
mysql>
mysql> drop table matches;
Query OK, 0 rows affected (0.00 sec)
mysql>
Related examples in the same category