Skip to Content

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

Due Date Calculation on A/R Invoice

The Due date calculation on an Invoice for a customer with a payment condition of 30 days is wrong on the system:

Invoice DocDate: 11.05.17

Invoice DueDate: 11.07.01

On the BP Master Data is set a payment condition of 30 days. So it should be a due date of June, not July. This is a invoice that comes from a Sales Order with Approval Procedure.

Our version is 2007 A SP:00 PL:49.

Thanks in Advance...

Former Member
Former Member replied

Hello,

Perfect Notification

-


For Payment Terms for Business Partner----


IF (@transaction_type = 'A' Or @transaction_type = 'U') AND @object_type = '17'

BEGIN

Declare @GroupNum as Nvarchar(20)

Declare @OCRDGroupNum as Nvarchar(20)

Declare @PaymentTermCode as Nvarchar(20)

Declare @PaymentTermName as Nvarchar(20)

Set @PaymentTermCode = (Select GroupNum from OCRD where CardCode = (Select CardCode from ORDR where DocEntry =@list_of_cols_val_tab_del))

Set @PaymentTermName = (Select PymntGroup from OCTG where GroupNum = @PaymentTermCode )

Set @GroupNum = (select GroupNum from ORDR where DocEntry =@list_of_cols_val_tab_del)

Set @OCRDGroupNum =(Select GroupNum from OCRD where CardCode = (Select CardCode from ORDR where DocEntry =@list_of_cols_val_tab_del))

If @GroupNum != @OCRDGroupNum

begin

SET @error = 10

SET @error_message = N'Payment Terms Should be ' + ' ' + @PaymentTermName + ' ' +' For this Business Partner'

end

END

-


End----


It will Definatillly Help You.

Thanks

Manvendra Singh Niranjan

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question