Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8940

Re: Transaction Notification for compare Purchase Order price to Last Goods Receipt PO Price

$
0
0

Hi Mustafa,

 

I solve my requirement using above transaction notification code.

 

IF (@transaction_type = 'A' or @transaction_type = 'U') AND @object_type = '22' 
BEGIN
if exists (select Top 1 POR1.Price, PDN1.Price from POR1
INNER JOIN OPOR ON OPOR.DocEntry = POR1.DocEntry 
INNER JOIN PDN1 ON PDN1.ItemCode = POR1.ItemCode
INNER JOIN OPDN ON OPDN.DocEntry = PDN1.DocEntry
WHERE (PDN1.ItemCode = POR1.ItemCode AND ((POR1.Price-PDN1.Price)*100/PDN1.Price) > 10
and OPOR.DocEntry=@list_of_cols_val_tab_del) order by OPDN.DocDate Desc)    begin        SET @error = 221        SET @error_message = 'Selected Item Exists from 10 % of Last GRN Price'    end
END

But thanks for your replay.

 

Regards,

Nishit Makadia


Viewing all articles
Browse latest Browse all 8940

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>