我想基於一個子查詢的結果插入,但我不斷收到同樣的錯誤:插入查詢
Operand should contain 1 column(s)
這裏的查詢:
INSERT INTO customer_entity_int
(attribute_id, entity_type_id, entity_id, `value`)
VALUES (14, (
SELECT entity_type_id, entity_id, `value`
FROM customer_entity_int
WHERE attribute_id = 13
AND entity_id NOT
IN (
SELECT entity_id
FROM customer_entity_int
WHERE attribute_id = 14
)
))
哪有我爲我的插入選擇多個列?
完美,這工作很好,我會盡快接受它 – BenOfTheNorth 2013-03-06 10:32:06