INSERT INTO faketable(blob1, name, bitfield) values(b'001011101', "Beeblebrox", b'1');
You can also print out the binary data in a way that's not going to ruin your terminal using the BIN(), OCT() and HEX() functions:
SELECT name, HEX(blob1), BIN(bitfield) from faketable;
+--------------------+--------------+----------------+
| name | HEX(blob1) | BIN(bitfield) |
+--------------------+--------------+----------------+
| Beeblebrox | 005D | 1 |
+--------------------+--------------+----------------+
No comments:
Post a Comment