SQL Server administration and T-SQL development, Web Programming with ASP.NET, HTML5 and Javascript, Windows Phone 8 app development, SAP Smartforms and ABAP Programming, Windows 7, Visual Studio and MS Office software
Development resources, articles, tutorials, code samples, tools and downloads for SAP HANA and ABAP, HANA Database, SQLScript, SAP UI5, Screen Personas, Web Dynpro, Workflow

SAP Payment Terms Table and ZTERM Texts Table for ABAP Developers

ABAP developers frequently use Payment Terms ZTERM especially on SAP Smartform output documents.
ABAP developers will find two common SAP tables T052 and TVZBT that can be used to query detailed data about payment terms used in SAP documents.
On the other hand, ABAP function module FI_PRINT_ZTERM can be used to read translated text of a payment term ZTERM code in specified language as an advanced method.

Payment Terms

ABAP developers can use the SAP table T052 (Terms of Payment) in order to get details about the ZTERM payment terms of an order or invoice. The SAP Table T052 Terms of Payment has the following table columns.

ZTERMTerms of payment key
ZTAGGDay Limit
ZDARTDate Type
ZFAELCalendar Day for the Baseline Date for Payment
ZMONAAdditional Months
ZTAG1Days from Baseline Date for Payment
ZPRZ1Cash Discount Percentage Rate
ZTAG2Days from Baseline Date for Payment
ZPRZ2Cash Discount Percentage Rate
ZTAG3Days from Baseline Date for Payment
ZSTG1Due Date for Special Condition
ZSMN1Additional Months for Special Condition (Term 1)
ZSTG2Due Date for Special Condition
ZSMN2Additional Months for Special Condition (Term 2)
ZSTG3Due Date for Special Condition
ZSMN3Additional Months for Special Condition (Term 3)
XZBRVPrint terms of payment in RV papers
ZSCHFPayment Block (Default Value)
XCHPBTransfer payment block when changing terms of payment?
TXN08Number of the standard text
ZLSCHPayment method
XCHPMTransfer payment method when changing terms of payment?
KOARTAccount Type of the Customer/Vendor
XSPLTIndicator: Term for installment payment
XSCRCRecurring Entries: Add Terms of Payment from Master Record

Payment Terms Texts Table

If as an ABAP developer, you want to display payments terms text in different languages, you can read ZTERM text from SAP table TVZBT, Customers: Terms of Payment Texts table or SAP table T052U, Own Explanations for Terms of Payment.

Customers: Terms of Payment Texts TVZBT table has the following table columns.

SPRASLanguage Key
ZTERMTerms of payment key
VTEXTDescription of terms of payment

SAP table T052U Own Explanations for Terms of Payment has following fields:

SPRASLanguage Key
ZTERMTerms of Payment Key
ZTAGGDay Limit
TEXT1Own Explanation of Term of Payment

Read Payment Term Texts by Code in ABAP

ABAP programmers can use following methods in their ABAP codes or programs to read payment term description in a specific language.
ABAP developer can either query SAP tables tvzbt or t052 for the payment term text translation or better use ABAP function module FI_PRINT_ZTERM or a similar one to get ZTERM translated text.

DATA lv_zterm TYPE dzterm VALUE 'A00C'.
DATA lv_spras TYPE spras VALUE 'T'.

SELECT SINGLE * FROM t052 INTO @DATA(ls_t052) WHERE zterm = @lv_zterm.
CHECK sy-subrc = 0.
SELECT SINGLE vtext FROM tvzbt INTO @DATA(lv_vtext) WHERE zterm = @lv_zterm AND spras = @lv_spras.
IF sy-subrc = 0.
 WRITE lv_vtext. " translation from TVZBT table
SELECT SINGLE text1 FROM t052u INTO @DATA(lv_text1) WHERE zterm = @lv_zterm AND spras = @lv_spras.
IF sy-subrc = 0.
 WRITE lv_text1. " translation from T052U table

DATA lt_ztext LIKE TABLE OF ttext.
  i_zterm = lv_zterm
  i_langu = lv_spras
* I_XT052U = ' '
* I_T052 =
  t_ztext = lt_ztext
* OTHERS = 2.

IF sy-subrc = 0.
 LOOP AT lt_ztext INTO DATA(ls_ztext) WHERE text1 IS NOT INITIAL.
  WRITE :/ lv_zterm, lv_spras, ls_ztext-text1.

SAP ZTERM payment term text translation in ABAP

Here is the output of the above ABAP report with sample data querying ZTERM in ABAP tables for Turkish language translation.
Please note that although there is not a record in ABAP tables TVZBT or T052U, the ABAP function module FI_PRINT_ZTERM is capable of generating the payment term text using text symbols used in the program.


Install SAP Free
CRM Companies List
Web Based CRM Software

Copyright © 2004 - 2021 Eralper YILMAZ. All rights reserved.