This commit is contained in:
Paul Trowbridge 2025-08-18 14:33:38 -04:00
parent f1d4d8a60b
commit d2f56fcafa
2 changed files with 18 additions and 8 deletions

View File

@ -7,12 +7,22 @@ EXEC pricing.single_price_call
@vol = 9600;
EXEC pricing.single_price_call
@bill = 'BFGS0001',
@ship = 'BOBS0002',
@part = 'HTI10754B12B024LXB04',
@v1ds = 'v1:L.L.PLT..',
@bill = 'FARM0001',
@ship = 'KEYB0001',
@part = 'HCA10000B661100',
@v1ds = 'v1:T..CSE..D',
@vol = 172000;
SELECT g.*
FROM (SELECT
TRY_CAST(.33275 AS NUMERIC(20,5)) AS tprice,
TRY_CAST(.758 AS NUMERIC(20,5)) AS last_price_norm,
TRY_CAST(null AS NUMERIC(20,5)) AS listprice_eff,
TRY_CAST('2025-06-01' AS DATE) AS last_date
) q
CROSS APPLY pricing.guidance_logic(q.tprice, q.last_price_norm, q.listprice_eff, q.last_date, 0.05, 1.0, 1.0) g;
SELECT * FROM pricing.lastpricedetail l WHERE customer = 'HYBELS' AND l.partgroup = 'HZP3E100'
SELECT * FROM pricing.pricelist_ranged pr WHERE pr.jcpart = 'XNS0T1G3G18B096' AND

View File

@ -3,8 +3,8 @@ SELECT
FROM pricequote.single_price_call(
'FARM0001',
'KEYB0001',
'HZP3E103E21D050',
'v1:C..BDL..',
'HCA10000B661100',
'v1:T..CSE..D',
50000
) f
@ -38,5 +38,5 @@ FROM
billto, shipto, part, v1ds, units_each
) pc ON TRUE
WHERE
qid = 113278
AND qrn = 5
qid = 113173
AND qrn = 32