SAP DDIF_NAMETAB_GET Function Module for DD: Interface to Read a Runtime Object from the ABAP Dictionary
DDIF_NAMETAB_GET is a standard ddif nametab get SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for DD: Interface to Read a Runtime Object from the ABAP Dictionary processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for ddif nametab get FM, simply by entering the name DDIF_NAMETAB_GET into the relevant SAP transaction such as SE37 or SE38.
Function Group: SDIFRUNTIME
Program Name: SAPLSDIFRUNTIME
Main Program: SAPLSDIFRUNTIME
Appliation area: S
Release date: 25-Dec-1999
Mode(Normal, Remote etc): Normal Function Module
Update:
Function DDIF_NAMETAB_GET pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'DDIF_NAMETAB_GET'"DD: Interface to Read a Runtime Object from the ABAP Dictionary.
EXPORTING
TABNAME = "Name of Table (of the Type)
* ALL_TYPES = ' ' "Take Runtime Objects for All Types into Consideration
* LFIELDNAME = ' ' "Poss. Long Field Name of Search Field
* GROUP_NAMES = ' ' "Take Named Includes into Consideration
* UCLEN = "Unicode length with which runtime object was generated
* STATUS = 'A' "Activation Status of a Repository Object
IMPORTING
X030L_WA = "Header Information of Runtime Object
DTELINFO_WA = "Decoded Information about a Data Element
TTYPINFO_WA = "Encoded Information about a Table Type
DDOBJTYPE = "Kind of Type
DFIES_WA = "Field Information (Without Domain and Text)
LINES_DESCR = "Information about Other Referenced Types
TABLES
* X031L_TAB = "Field List of Runtime Object (Technical View)
* DFIES_TAB = "Decoded Field Information WITHOUT Domain and Text Information
EXCEPTIONS
NOT_FOUND = 1
IMPORTING Parameters details for DDIF_NAMETAB_GET
TABNAME - Name of Table (of the Type)
Data type: DDOBJNAMEOptional: No
Call by Reference: Yes
ALL_TYPES - Take Runtime Objects for All Types into Consideration
Data type: DDBOOL_DDefault: ' '
Optional: Yes
Call by Reference: Yes
LFIELDNAME - Poss. Long Field Name of Search Field
Data type: DFIES-LFIELDNAMEDefault: ' '
Optional: Yes
Call by Reference: Yes
GROUP_NAMES - Take Named Includes into Consideration
Data type: DDBOOL_DDefault: ' '
Optional: Yes
Call by Reference: Yes
UCLEN - Unicode length with which runtime object was generated
Data type: UNICODELGOptional: Yes
Call by Reference: Yes
STATUS - Activation Status of a Repository Object
Data type: AS4LOCALDefault: 'A'
Optional: Yes
Call by Reference: Yes
EXPORTING Parameters details for DDIF_NAMETAB_GET
X030L_WA - Header Information of Runtime Object
Data type: X030LOptional: No
Call by Reference: No ( called with pass by value option)
DTELINFO_WA - Decoded Information about a Data Element
Data type: DTELINFOOptional: No
Call by Reference: No ( called with pass by value option)
TTYPINFO_WA - Encoded Information about a Table Type
Data type: TTYPINFOOptional: No
Call by Reference: No ( called with pass by value option)
DDOBJTYPE - Kind of Type
Data type: DD02V-TABCLASSOptional: No
Call by Reference: No ( called with pass by value option)
DFIES_WA - Field Information (Without Domain and Text)
Data type: DFIESOptional: No
Call by Reference: Yes
LINES_DESCR - Information about Other Referenced Types
Data type: DDTYPELISTOptional: No
Call by Reference: Yes
TABLES Parameters details for DDIF_NAMETAB_GET
X031L_TAB - Field List of Runtime Object (Technical View)
Data type: X031LOptional: Yes
Call by Reference: Yes
DFIES_TAB - Decoded Field Information WITHOUT Domain and Text Information
Data type: DFIESOptional: Yes
Call by Reference: Yes
EXCEPTIONS details
NOT_FOUND - No Active Runtime Object Found for TABNAME
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for DDIF_NAMETAB_GET Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.DATA: | ||||
lv_tabname | TYPE DDOBJNAME, " | |||
lv_x030l_wa | TYPE X030L, " | |||
lv_not_found | TYPE X030L, " | |||
lt_x031l_tab | TYPE STANDARD TABLE OF X031L, " | |||
lv_all_types | TYPE DDBOOL_D, " ' ' | |||
lt_dfies_tab | TYPE STANDARD TABLE OF DFIES, " | |||
lv_dtelinfo_wa | TYPE DTELINFO, " | |||
lv_lfieldname | TYPE DFIES-LFIELDNAME, " ' ' | |||
lv_ttypinfo_wa | TYPE TTYPINFO, " | |||
lv_ddobjtype | TYPE DD02V-TABCLASS, " | |||
lv_group_names | TYPE DDBOOL_D, " ' ' | |||
lv_uclen | TYPE UNICODELG, " | |||
lv_dfies_wa | TYPE DFIES, " | |||
lv_status | TYPE AS4LOCAL, " 'A' | |||
lv_lines_descr | TYPE DDTYPELIST. " |
  CALL FUNCTION 'DDIF_NAMETAB_GET' "DD: Interface to Read a Runtime Object from the ABAP Dictionary |
EXPORTING | ||
TABNAME | = lv_tabname | |
ALL_TYPES | = lv_all_types | |
LFIELDNAME | = lv_lfieldname | |
GROUP_NAMES | = lv_group_names | |
UCLEN | = lv_uclen | |
STATUS | = lv_status | |
IMPORTING | ||
X030L_WA | = lv_x030l_wa | |
DTELINFO_WA | = lv_dtelinfo_wa | |
TTYPINFO_WA | = lv_ttypinfo_wa | |
DDOBJTYPE | = lv_ddobjtype | |
DFIES_WA | = lv_dfies_wa | |
LINES_DESCR | = lv_lines_descr | |
TABLES | ||
X031L_TAB | = lt_x031l_tab | |
DFIES_TAB | = lt_dfies_tab | |
EXCEPTIONS | ||
NOT_FOUND = 1 | ||
. " DDIF_NAMETAB_GET |
ABAP code using 7.40 inline data declarations to call FM DDIF_NAMETAB_GET
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.DATA(ld_all_types) | = ' '. | |||
"SELECT single LFIELDNAME FROM DFIES INTO @DATA(ld_lfieldname). | ||||
DATA(ld_lfieldname) | = ' '. | |||
"SELECT single TABCLASS FROM DD02V INTO @DATA(ld_ddobjtype). | ||||
DATA(ld_group_names) | = ' '. | |||
DATA(ld_status) | = 'A'. | |||
Search for further information about these or an SAP related objects