sql >> Base de Datos >  >> RDS >> Mysql

¿Cómo almacenar varbinary en MySQL?

Los datos imprimibles se pueden insertar usando comillas. Los datos no imprimibles se pueden insertar utilizando valores hexadecimales. Es decir:

INSERT INTO Table(VarBinaryColumn) VALUES('Printable data') -- Will be stored as binary representation using the charset of the operating system

INSERT INTO Table(VarBinaryColumn) VALUES(0x12345) -- Non-printable binary data