Skip to Content
author's profile photo Former Member
Former Member

Itemcode cannot be deleted from production order except authorize users

i was added one udf in ousr if U_prd_a is 'y' than the user is authorized to deleted the same from production order as well as in BOM .need the SP_transaction code for the same .  tried to use code from this post
IF @transaction_type IN ('A', 'U')AND @object_type in ('202')


If exists (SELECT T0.DocEntry FROM owor T0

inner join itt1 t2 on t2.father = T0.Itemcode

where t0.DocEntry =@list_of_cols_val_tab_del AND t2.code not in (SELECT T1.itemcode FROM wor1 t1 where t0.docentry = t1.docentry))


SET @error = '202'

SET @error_message = N'order can not be added if not match with BOM.'


Add comment
10|10000 characters needed characters exceeded

0 Answers