更新时间:2023-11-29 23:16:28
您可以获取所有与产品ID不符的记录的总和.
将会是这样的:
You can get the sum of all records where the product ID doesn''t match the one in question.
It will be something like this:
@comparisonProductID
select
sum(p.qty_supplied)
, sum(p.qty_returned)
from
product_info_table p
where
p.product ID <> @comparisonProductID
干杯.
Cheers.