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

EXPORT /IMPORT statements

Former Member
0 Likes
3,939

Hello,

Before running a transaction using batch input I export a variable to memory using:

EXPORT var TO MEMORY ID 'ID_CODE'.

Then, in a user exit of that tcode I'd like to import that variable from memory using:

IMPORT var FROM MEMORY ID 'ID_CODE'.

This does not work.

Any idea on how should I do it correctly?

Thanks.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,693

Hi,

IMPORT and EXPORT statements are session memory. The subsequent transaction should be executed immediately.

If possible try using SET PARAMETER ID and GET PARAMETER ID for the required field...

Prem.

6 REPLIES 6
Read only

Former Member
0 Likes
1,693

Hi

Export to memory id works only when you keep running the same session,

for keeping data across the session, export your data to sap memory(cluster table)...

Just do an F1 on EXPORT to get the exact syntax....

Cheers

Ravish

Read only

Former Member
0 Likes
1,693

Hi,

IF you are using Session method it will not work.Session method does not supports real time processing as it its processing is Asynchronous..

SO use Call transaction method this will work..

Just Specify whats the BDCmethod you are using.

Regards,

Gurpreet

Read only

Former Member
0 Likes
1,694

Hi,

IMPORT and EXPORT statements are session memory. The subsequent transaction should be executed immediately.

If possible try using SET PARAMETER ID and GET PARAMETER ID for the required field...

Prem.

Read only

Subhankar
Active Contributor
0 Likes
1,693

Hi ..

Please the sample code.

export i_data = i_data to memory id 'EDD0595'.

import i_data = i_data from memory id 'EDD0595'.

Read only

former_member156446
Active Contributor
0 Likes
1,693

if its a variable and not a table you should be fine using set parameter and get parameter.. please hit F1 on this words in ABAP editor, SAP help will give you the required info...

Read only

apachon
Participant
0 Likes
1,693

Hi.

Export

EXPORT lv_variable TO SHARED MEMORY indx(zk) ID 'WEBAZZ'.

Import

IMPORT lv_variable TO lv_c_variable FROM SHARED MEMORY indx(zk) ID 'WEBAZZ'.

You can also use Shared Memory Objects – Transfer data between ABAP programs | SAP Blogs