on 2024 Mar 12 8:05 AM
Hi,
I want to block few users from cancelling AR invoice document. I have tried the following Transaction Notification on HANA database.
It is not working.
Could you please help on this.
Request clarification before answering.
Hi @Swathy ,
If ( :object_type = '13' AND :transaction_type = 'A')
THEN
DECLARE temp_var_0 INT := 0;
SELECT COUNT(B."DocEntry") INTO temp_var_0
FROM OINV B
LEFT OUTER JOIN OUSR C ON B."UserSign" = C."USERID"
WHERE B.CANCELED IN ('C','Y') AND C."U_NAME" NOT IN ('cwi01','cwi03','cwi04') AND B."DocEntry" =:list_of_cols_val_tab_del;
IF :temp_var_0>0
THEN
error:=503;
error_message:='Cancellation is not allowed';
END IF;
END IF;
When you try to cancel the AR Invoice document, a cancellation document is added therefor the transaction type will be [A]dd.
For Cancellation you can check the CANCELED column.
Thanks.
Manish.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
39 | |
8 | |
5 | |
3 | |
3 | |
3 | |
3 | |
2 | |
2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.