Skip to Content
avatar image
Former Member

Global variable in a function group is saved in SAP memory or abap memory?

In my debugging, i found the global variables value can not be accessed in some cases for the Function modules in the same function group.

So i want to confirm if the value of gloable variables is only saved in abap memory or SAP memory.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Best Answer
    Mar 29, 2016 at 08:42 PM

    None of them 😊 abap memory is for export/import memory id, and sap memory is for set/get parameter id

    Maybe your issue is about parameters from function modules defined with a global interface (obsolete, but old function module may still have them). You can access them only when the function module is in the stack (it's a kind of global field symbol pointing to a local data object i.e. the parameter).

    There can be other possibilities, but I guess the previous

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 30, 2016 at 05:22 AM

    Hello Rio Chang,

    As correctly pointed by Sandra, the global variables value is saved neither in ABAP memory nor SAP Memory.

    I suppose you have a top include with all the global data declaration, used by all Function modules in the function group. The values of these variables are saved in temporary memory at run time, and are available for the particular session.

    Also check that global variables in one function module are not cleared, if you want to use the same values is another function module as well.

    Please elaborate the issue further so we can understand and respond better.

    You may visit the below link for another chain on global variables:

    http://scn.sap.com/thread/1066150

    Thanks and Regards,

    Sheily Babel.

    Add comment
    10|10000 characters needed characters exceeded