Skip to Content
0
5 days ago

SP_Notification Error

63 Views

Hi,

Please any help me about below stored procedure. I added pricelist =1. But I need add Pricelist 1 & 3.

How to add pricelist 1 & 3 in the below stored Procedure
IF :OBJECT_TYPE = '17' AND (:TRANSACTION_TYPE ='A' OR :TRANSACTION_TYPE ='U')

THEN

DECLARE LineNum NVARCHAR;

select MAX (T1."LineNum") INTO LineNum FROM RDR1 T1 INNER JOIN ORDR T0 ON T0."DocEntry" = T1."DocEntry"

inner join ITM1 T2 on T1."ItemCode" = T2."ItemCode" and T2."PriceList" = '1'

Left outer join OITM T3 ON T3."ItemCode" = T1."ItemCode"

WHERE T1."DocEntry" = :list_of_cols_val_tab_del and T1."PriceBefDi" < T2."Price" AND T0."UserSign" not in ('1','119','120');

IF :LineNum != ''

THEN

error := 160901;

error_message := Concat(N'Not allow to reduce the Base Prices for the Items Applied by management. Please Contact Management, Please Check Line Item - ', LineNum+1);

CNT3 =0;

END IF;

END IF;