I'm having troubles using the LOAD_FILE() function in my environment.
I'm trying to add a file to a BLOB field but whenever I try to insert or update this field with LOAD_FILE(), this field is being set as NULL.
I already checked all common problems which includes system variables, file size and max packet Size and permission problems (Both DB and Linux permissions), even some workaround that included moving the file to a Mysql Owned directory, the problem persists.
Do note that when using LOAD_FILE in a statement similar to
does work and the file raw data gets displayed, either via CLI or using a DBA tool like DBeaver.
Dump of the table:
CREATE TABLE `table` ( `id` int(11) NOT NULL AUTO_INCREMENT, `string` varchar(3) NOT NULL, `blob` blob NOT NULL, PRIMARY KEY (`id`), ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
Each file size I want to insert is around 8kb in size.
I'd appreciate any help with this issue.