スクリーンショットを見ると、各場所のタグの数に基づいて複製されているように見えます。これは、場所をフィルタリングできるようにするためのタグの結合によるものです。クエリに個別の値を追加することで、重複するデータベース値を削除します。それを行った後、特定の部品に対して同じ数量と同じ金額の購入を行った場合は表示されないため、重複値の表示をオンに戻すことをお勧めします。
SELECT DISTINCT costlayer.qty AS Qty, costlayer.orgqty, costlayer.orgtotalcost,
costlayer.totalcost AS TotalCost, costlayer.datecreated AS DateCreated,
part.num AS PartNumber, part.description as PartDescription, asaccount.name as "InventoryAccount",
company.name AS company, currency.symbol
FROM CostLayer
LEFT JOIN Part ON part.id = costlayer.partid
LEFT JOIN Tag ON part.id = tag.partId
LEFT JOIN Location ON tag.locationId = location.id
LEFT JOIN LocationGroup ON location.locationGroupId = locationGroup.id
LEFT JOIN asaccount ON part.inventoryaccountid = asaccount.id
JOIN company ON company.id = 1
LEFT JOIN currency ON currency.homeCurrency = 1
WHERE costlayer.datecreated BETWEEN $P{dateRange1} AND $P{dateRange2}
AND costlayer.statusid IN ($P!{ckShowActiveCostingLayers},$P!{ckShowFulfilledCostingLayers},$P!{ckShowVoidedCostingLayers})
AND UPPER(part.num) LIKE UPPER($P{partNum})
AND (UPPER(COALESCE(asaccount.name,'')) LIKE UPPER('%' || $P{AssetAccount} || '%'))
AND LocationGroup.id LIKE $P{locationGroupID}
ORDER BY (CASE WHEN $P{AssetAccount} NOT LIKE CAST('%' AS varchar(256)) THEN asaccount.name ELSE part.num END), part.num ASC, costlayer.id, costlayer.datecreated