I'm saving files in my MySQL database on a LONGBLOB column and when I perform a select in my IDE I notice some of the base64 file content has the message 206.2 kB (204.8 kB loaded)
prepended to it.
I'm using PHP to prepare the data and perform the inserts to the db:
$file = file_get_contents('path/to/file.pdf');
$encodedFile = base64_encode($file);
Does anyone know how is this happening?
It turns out this is being imposed by the IDE I'm using, which is PHPStorm, to avoid memory exhaustion on the computer.
If I use mysql cli on the terminal all values show fine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With