Jidic
Jidic

Reputation: 147

How to add add an image in a table using MySqlWorkbench?

I'm trying to fill a table called book, in particular I need to insert an image in the field image of that table. This is the structure:

CREATE TABLE IF NOT EXISTS `ods`.`books` (
  `id` INT NOT NULL,
  `name` VARCHAR(255) NOT NULL,
  `site` VARCHAR(255) NOT NULL,
  `image` BLOB NOT NULL,
  PRIMARY KEY (`id`))
ENGINE = InnoDB;

this is the window of the software:

enter image description here

How can I add an image using the inserts windows of MySqlWorkbench?

Thanks.

Upvotes: 1

Views: 4754

Answers (1)

Jacob
Jacob

Reputation: 1916

Right click the blob field -> Load Value From File

enter image description here

Upvotes: 4

Related Questions