Preface – This post is part of the ABAP Beginner series.
Table of Contents
SAP Memory and ABAP Memory: Different types of Memory in SAP
In this post we will discuss SAP Memory and ABAP Memory i.e. ABAP memory organization with reference to the ABAP program; that is, which memory is accessed by an ABAP program. There are three types of memory in SAP system:
- SAP Memory / Shared Memory
- User Memory
- ABAP Memory
SAP Memory / Shared Memory
- In our previous post, we talked about sessions. SAP memory will have access of all the main sessions within the SAP GUI.
- You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another.
- An ABAP program uses SET/GET parameters to access SAP memory. These parameters are set for a particular user or program using the SET PARAMETER statement. Other ABAP programs retrieve the already set parameters using the GET PARAMETER statement.
- The most frequent use of SPA/GPA parameters is to fill input fields on screens
User Memory is the memory that is allocated for each user who is logged in. A user session is assigned its own memory area of the user memory, in which SPA/GPA parameters can be stored.SPA/GPA parameters are set using SET PARAMETER and read using GET PARAMETER.
- Each SAP session contains an area called ABAP memory. ABAP memory is available to all internal sessions.
- ABAP programs uses the EXPORT and IMPORT statements to access it.
- All ABAP programs can also access the SAP memory.