1

ERROR 1366: 1366: Incorrect integer value: '' for column 'subcategory_id' at row 1 SQL Statement:

INSERT INTO `db`.`shelf` (`shelf_id`, `model_code_name`, `customer_friendly_name`, `sku_code`, `description`, `unitmeasure_id`, `category_id`, `subcategory_id`, `colour`, `size`, `vendor_id`) 
VALUES ('919025', '', 'MS919025', 'NULL', '1', '3', '31', '', 'W1800*D900*H724MM', '10', '')

2 Answers 2

1

'' is not integer (between 31 and W1800)

Sign up to request clarification or add additional context in comments.

Comments

1

You need to make the value of subcategory_id as integer value rather than ''

So the query should be like

INSERT INTO db.shelf (shelf_id, model_code_name, customer_friendly_name, sku_code, description, unitmeasure_id, category_id, subcategory_id, colour, size, vendor_id) 
VALUES ('919025', '', 'MS919025', 'NULL', '1', '3', '31', someintegervalue, 'W1800*D900*H724MM', '10', '')
                                                           ^^^^^^^^^^^^^^^

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.