Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Replacement of Function module in ECC 6.0

Former Member
0 Likes
1,111

Hello All,

The Function module 'NAMETAB_GET' is shown to be obsolete in ECC 6.0 .

Please suggest which of the function modules among 'DDIF_FIELDINFO_GET' and 'DDIF_NAMETAB_GET' can be used as a replacement for the same.

Also ,it would be helpful if the use of these function modules is mentioned.

Best Regards,

Lavanya.

Hello All,

The Function module 'NAMETAB_GET' is shown to be obsolete in ECC 6.0 .

Please suggest which of the function modules among 'DDIF_FIELDINFO_GET' and 'DDIF_NAMETAB_GET' can be used as a replacement for the same.

Also ,it would be helpful if the use of these function modules is mentioned.

Best Regards,

Lavanya.

4 REPLIES 4
Read only

GauthamV
Active Contributor
0 Likes
968

Use this.

DDIF_FIELDINFO_GET

Read only

Former Member
0 Likes
968

use 'DDIF_NAMETAB_GET'

Functionality

This function module reads the runtime information (nametab) of a table or in general of any type of the ABAP Dictionary. However, the runtime information does not contain any text. You should use the function module DDIF_FIELDINFO_GET to read the runtime information including text (or to determine the domain for table fields).

The types of the ABAP Dictionary are divided into data elements, structured types and table types.

A structured type consists of a sequence of components that are each identified by a unique name. A type is defined for each of these components. In addition to the types of the ABAP Dictionary, you can also use the built-in types of the R/3 System (CHAR, NUMC,...) to define the types of the components.

All its components as well as the fields of its structured components are called the fields of a structured type. The name of a field no longer uniquely identifies it within a structured type. For example, a structured type S could have a structured component F, which itself has a component called F. In this case S would have two fields with the name F. For this reason, its long field name is used to identify a field within a structured type. The long field name is the same as the name of the components for the components of the structured type itself. For the fields of a structured component, the long field name is a concatenation of the name of this structured component, the separator '-' and the long field name of the field in the structured component.

A field whose type is defined by a data element or a built-in type is also called an elementary type. A structured type whose components are all defined as elementary types is called flat. All other structured types are called deep.

This module gets the runtime information for the type whose name is defined in the IMPORT parameter TABNAME. If there is no such type, the exception NOT_FOUND is triggered.

Caution: If the IMPORT parameter ALL_TYPES is not set, only flat structured types are taken into consideration. In this case the exception is also triggered if the specified type is a data element, deep structure or a table type.

If the IMPORT parameter LFIELDNAME is not initial, only structured types having a field with the long name defined by LFIELDNAME are taken into consideration. The exception NOT_FOUND is triggered for all other types.

The internal representation of the runtime object is returned in parameters X030L_WA and X031L_TAB. Depending on the type category, this information is then edited in the corresponding parameters (see documentation about the parameters).

Notes

1. If parameter LFIELDNAME is not initial, X031L_TAB nevertheless contains the description of all fields of the structured type. The decoded form is only determined for the specified field, and the result is copied to DFIES_WA instead of DFIES_TAB. Since decoding for all the fields often takes up most of the runtime for this module, you should set parameter LFIELDNAME if you only need information about one field of the structured type.

This module gets the runtime information about a type. This means that only the currently active version of the type is taken into consideration. If none exists, the exception NOT_FOUND is triggered.

The corresponding function module DDIF_<object type>_GET is used to read the actual definition of a type of the ABAP Dictionary.

Caution: These read modules are much less efficient than the modules for defining the runtime information. You should therefore only use them if the runtime information is not sufficient.

2. The documentation for IMPORT parameter GROUP_NAMES describes how to handle named includes.

Read only

Former Member
0 Likes
968

Hello Gautham,

Thank you for the response.But why is that the Function Module - DDIF_FIELDINFO_GET is used instead of DDIF_NAMETAB_GET.

Best Regards,

Lavanya

Read only

Former Member
0 Likes
968

'DDIF_FIELDINFO_GET' can be used in the folowing reuirements.

-


This module provides the runtime information of the table. If the

description of the table is required as presented in the maintenance

transaction of the ABAP Dictionary, you should use the function

module DDIF_TABL_GET (or DDIF_DTEL_GET or DDIF_TTYP_GET).

This module only gets the data of the defined parameters. You should

therefore only define the parameters whose contents are to be

defined when you execute the call. For example, if you do not need

any information about the fixed values of the types that were

handled, you should not define the TABLES parameter FIXED_VALUES in

the call.

If both IMPORT parameters FIELDNAME and LFIELDNAME do not have

initial value, both restrictions are analyzed. The results can be

found in DFIES_WA.

DDIF_NAMETAB_GET can be used in the folowing reuirements.

-


This module gets the runtime information about a type. This means that

only the currently active version of the type is taken into

consideration. If none exists, the exception NOT_FOUND is triggered.

The corresponding function module DDIF_<object type>_GET is used to read

the actual definition of a type of the ABAP Dictionary.

Caution: These read modules are much less efficient than the modules for

defining the runtime information. You should therefore only use them if

the runtime information is not sufficient.

select one of these function modules based on ur requirement

Rgds,

Kiran