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

Finding the program that uses the specific MEMORY ID

Former Member
0 Likes
3,923

Hi SAP Experts,

Is there a way to find the specific MEMORY ID?

This is the only code I have so far.

" IMPORT lv_strec TO lv_str FROM MEMORY ID c_id.
FREE MEMORY ID c_id."

Thanks and Regards,

Luiz Carlos

1 ACCEPTED SOLUTION
Read only

Flavio
Active Contributor
3,745

Hi Luiz Carlos,

one possibility is to run an ABAP source code scan with

RPR_ABAP_SOURCE_SCAN

Thanks and regards,

Flavio

7 REPLIES 7
Read only

Flavio
Active Contributor
3,746

Hi Luiz Carlos,

one possibility is to run an ABAP source code scan with

RPR_ABAP_SOURCE_SCAN

Thanks and regards,

Flavio

Read only

Former Member
3,745

Hi Flavio,

I tried doing that with search string 'memory id' and even 'c_id' but can't find the program, am I missing some parameters that I need to input.




Thanks and Regards,
Luiz Carlos

Read only

0 Likes
3,745

If you are coming up with blanks, I would also suggest putting a wildcard into the Package field of the RPR_ABAP_SOURCE_SCAN selection screen. I use this program often to search our Z code. If I don't put Z* in the package field I don't get any hits.

Read only

Sandra_Rossi
Active Contributor
3,745

Prefer RS_ABAP_SOURCE_SCAN. It exists in all ABAP systems.

RPR_ABAP_SOURCE_SCAN exists only in SAP ERP or S/4HANA. And it now redirects to RS_ABAP_SOURCE_SCAN.

Read only

Flavio
Active Contributor
3,745

Hi Luiz Carlos,

answering your comment above, I believe you should enter c_id for the "String searched for" and the possible custom code wildcards, as follows (assuming the MEMORY ID is used in custom code, Z and Y namespaces) for "Program Name":

Thanks and best regards,

Flavio

Read only

Sandra_Rossi
Active Contributor
3,745

Instead of scanning the ABAP source codes (may take a long time), if you know the transaction code which runs this statement, you may run the transaction code:

  • with debug, add a break point on statements EXPORT TO MEMORY (and IMPORT FROM MEMORY eventually)
  • or with an ABAP trace in NON AGGREGATED mode, and you will see all EXPORT and IMPORT with the names of MEMORY ID.
Read only

matt
Active Contributor
3,745

The syntax is IMPORT FROM MEMORY ID id, where id is 'a flat character-like data object.' That means in your example, c_id is a constant (probably) defined somewhere in your program.

Therefore you need to find the value of c_id. You could do this by using F3 in Eclipse, or double clicking on the code line in SAPGui. Or in debug. Then search for that value. Searching for c_id therefore is not going to help you.

If the code you've posted is a standard sap program, it would be helpful to say which one.