這是爲我的論文和死衚衕是後來我不知道我在這裏做錯了什麼..我希望有人能幫助我知道這裏有什麼問題謝謝mysql#1242 - 子查詢返回多於1行
SELECT
flower_id,
flower_name,
flower_description,
flower_price,
flower_category,
(quantity - (SELECT
SUM(q.quantity_value)
FROM
orders_details od
INNER JOIN
cart_details cd ON cd.cart_id = od.cart_id
INNER JOIN
quantities q ON q.quantity_id = cd.quantity_id
WHERE
od.flag = 1 AND cd.flower_id = flower_id
GROUP BY cd.flower_id)) AS 'quantity',
mfg_date,
exp_date
FROM
flower_details,
categories
WHERE
flower_details.flower_category = categories.category_id
什麼IM這裏做的是讓產品從顧客買減去庫存股
你想要什麼?你有什麼? –
獲取產品庫存產品的差異總計 - 客戶購買的產品和產品的某些信息 –
嘗試僅執行子查詢並對其進行調試 – vstelmakh