Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Restriction for GRN not to Add more than1000 in Document total

Hi Expert ,

my client is doing direct GRN and asking whenever in GRN , DocTotal is more than 1000 then it should  give error that first Add Purchase Order .

what is the store Procedure .....??

Please help me Out for this .

Thanks

Sarvesh Gupta

replied

Hi

Try This

If @object_type='20' and @transaction_type in ('A','u')

BEGIN

If Exists (select * from PDN1 r inner join opdn r1 on r.docentry=r1.docentry

where isnull(r.Baseref,'') ='' and r1.DocType ='I' and r1.doctotal > 1000  and r1.DocEntry = @list_of_cols_val_tab_del   )

BEGIN

Select @error = -1,

@error_message = 'GRPO without PO is not allowed'

End

End

With Regards

Balaji Sampath

0 View this answer in context

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question