can u save internal table in sap memory from abap memory?

Answer Posted / shankar

If you want save ITAB in sap memory then you have to use
IMPORT nad EXPORT statements

The followin exapmles will explain how it will works
Here i created two report progrmas

1==> ZSHAN_EXPORT_ITAB ---> TO EXPORT THE ITAB INTO SAP
MEMORY

2==> ZSHAN_IMPORT_ITAB ---> TO IMPORT THE ITAB FROM SAP
MEMORY

---------------------------------------------

REPORT ZSHAN_EXPORT_ITAB.


DATA TEXT1(10) VALUE 'Exporting'.

DATA ITAB LIKE SBOOK OCCURS 10 WITH HEADER LINE.

DO 5 TIMES.
ITAB-BOOKID = 100 + SY-INDEX.
APPEND ITAB.
ENDDO.

EXPORT TEXT1 TEXT2 FROM 'Literal' TO MEMORY ID 'text'.

EXPORT ITAB TO MEMORY ID 'table'.

--------------------------------------------------------

===========================================================

--------------------------------------------------------
REPORT ZSHAN_IMPORT_ITAB.

DATA: TEXT1(10),
TEXT3 LIKE TEXT1 VALUE 'Initial'.

DATA JTAB LIKE SBOOK OCCURS 10 WITH HEADER LINE.

SUBMIT ZSHAN_EXPORT_ITAB AND RETURN.

IMPORT TEXT3 FROM MEMORY ID 'text'.
WRITE: / SY-SUBRC, TEXT3.

IMPORT TEXT2 TO TEXT1 FROM MEMORY ID 'text'.
WRITE: / SY-SUBRC, TEXT1.

IMPORT ITAB TO JTAB FROM MEMORY ID 'table'.

LOOP AT JTAB.
WRITE / JTAB-BOOKID.
ENDLOOP.
-----------------------------------------------------


I hope this information will help full.......

Is This Answer Correct ?    22 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Some Realtime Examples on Exits .

1910


How to copy table across clients?

825


Mention the various databases integrities?

804


how to read the standard field value in your custom program.

1218


What is locking ?

782


what is the exact code that shoud be implimented in sap note

2197


What do you mean by pooled tables in sap abap? Also explain what do you mean by table pool? : abap data dictionary

796


1.If there is one receiver,then To send 10 materials at a time through BD10 tcode, How many Master Idoc create? 2.If there is one receiver,then To send 1 material at a time through BD10 tcode, how many Master Idoc generated? 3.Can I Send Multiple Messges through BD10 tcode?

1725


What is the t-code for transaction recorder? : abap bdc

815


MY DOMAIN IS SAP-ABAP COMPARE TO WEBDYNPRO AND CRM-TECHNICAL WHICH IS BEST?

2687


What is repository info. Systems? : abap data dictionary

776


In selection screen, I have three fields, plant material number and material group. If I input plant how do I get the material number and material group based on plantdynamically?

838


What is the table & field to identify the no of items (bottles) stored in one case?

2195


Explain the function module in bdc?

798


Persistent class

1108