Merge branch 'master' of github.com:The-HC-Companies/price_api

This commit is contained in:
Paul Trowbridge 2025-08-01 15:17:28 -04:00
commit 904af8b9c9
2 changed files with 2 additions and 2 deletions

View File

@ -77,7 +77,7 @@ SELECT
,sel.avgfc
,sel.avgwt
,t.price
,round(CASE WHEN coalesce(t.price,0) <> 0 THEN (t.price-COALESCE(sel.avgfc,0))/t.price ELSE 0 END,3) futmarg
,round(CASE WHEN coalesce(t.price,0) <> 0 THEN (t.price-COALESCE(sel.avgsc,0))/t.price ELSE 0 END,3) curmarg
FROM
sel
LEFT OUTER JOIN pricequote.target_prices t ON

View File

@ -179,7 +179,7 @@ BEGIN
FROM pricequote.lastprice lp
WHERE
lp.customer = q.cust
AND lp.partgroup = SUBSTRING(q.part, 1, 8);
AND lp.partgroup = q.partgroup;
-----------------------------------------------------------------------
-- Step 5: Resolve best list price and insert it with list code