Ads

Data Types in SAP ABAP

Data Types in SAP ABAP

Every SAP ABAP basic learner should be start with data types which are root to implement the SAP applications .So, here i defined the brief introduction of data types.

Data Types: All programming languages distinguish between various types of data with various uses, such as.

Data types can be divided into elementary, reference, and complex types.

Elementary Types These are data types of fixed or variable length that are not made up of other types.

The difference between variable length data types and fixed length data types is that the length and the memory space required by data objects of variable length data types can change dynamically during runtime, and that these data types cannot be defined irreversibly while the data object is being declared.

Reference Types Reference types are deep data types that describe reference variables, that is, data objects that contain references.

Complex Data Types Complex data types are made up of other data types.

Examples for Complex Data Types The following list contains examples of complex data types in ascending order of complexity: Structures consisting of a series of elementary data types of fixed length An internal table whose line type is an elementary type.

Visibility of Data Types The predefined ABAP types are always visible.

You cannot declare types with the same names as these data types, either in the program or in the ABAP Dictionary.

All local data types in a program obscure data types with the same names in the ABAP Dictionary.

In the ABAP Dictionary, different visibility rules apply to standalone data types and the data types stored in type groups.

Data types in type groups obscure standalone data types with the same names.

Equally, you cannot create a type group if there is already a standalone data type with the same name followed by an underscore.

If you specify TYPE1 in a TYPE addition in the program, the system uses the ABAP Dictionary type both in the procedure and the main program.

Compatibility Two non-generic data types or data objects are referred to as compatible if all of their technical attributes are exactly the same.

Compatibility applies to fully-specified data types, since all data objects are fully typed at runtime.

Consequences of definition for the compatibility of data types: Elementary Data Types Elementary data types are compatible with other elementary data types if they are identical in type, field length, and the number of decimal places.

Elementary data types are not compatible with references or complex types.

References are not compatible with elementary data types or complex types.

Complex Data Types Complex data types are compatible with other complex data types if their construction rules are the same.

Complex data types are not compatible with elementary data types or references.

Comments

Popular posts from this blog

BADI Interview Questions in SAP ABAP

Sample SAP ABAP Programming Examples for Practice

Module Pool Programming Interview Questions and Answers in SAP ABAP

Step by Step tutorial on BDC Session Method Program in SAP ABAP

SAP ABAP Interview Questions and Answers for 10 Years Experienced