在 1_products t2 我还有其他名为 make,model 的列
当我添加它们时
(SELECT
t2.code,t2.make,t2.model
FROM .....
我明白了
错误 1241 操作数应包含 1 列
SELECT
t1.fk_products_id,
(SELECT
t2.code
FROM
1_products t2
WHERE
t2.id = t1.fk_products_id
order by code
limit 1)
FROM
1_stock t1
WHERE
t1.branch = 1 and t1.dispatch <> 0;