MySQL Forums
Forum List  »  PHP

Updating a blob
Posted by: Rich Bernstein
Date: March 20, 2021 11:17PM

I am trying to insert an image (in a string) into a blob on mysql rds.
$szFile3 = file_get_contents($szFile);
$imgData = addslashes($szFile3);
$BLOB_insert = array(
"id" => $primary_key,
"image_BLOB" => $imgData
);
$iRc=$this->db->update($_SESSION[table],$BLOB_insert);

When I run the update the return code is null. I then view the table in mysqlWorkbench but the blob field appears to be NULL.How can I see what the error is?

Options: ReplyQuote


Subject
Written By
Posted
Updating a blob
March 20, 2021 11:17PM
March 22, 2021 11:04AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.