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

Syntax Error with EXPORT statement in ECC 6

Former Member
0 Likes
1,201

Hi All,

I have one issue with EXPORT statement syntax.

I have declared data like below:

DATA: BEGIN OF mem_id,

mandt LIKE sy-mandt,

uname LIKE sy-uname,

modno LIKE sy-modno,

END OF mem_id.

  • export the memory id

EXPORT E_VBKOK XANZPK TEXTTAB XBOLNR TO MEMORY ID MEM_ID.

When I am checking the syntax error i am getting like "MEM_ID" must be a character-type field (data type C, N, D or T). by "INTERFACE". by "INTERFACE". "INTERFACE". by "INTERFACE". by "INTERFACE".

I know this statement would be like IMPORT ITAB TO JTAB FROM MEMORY ID 'table'. So I have written like below

EXPORT E_VBKOK XANZPK TEXTTAB XBOLNR TO MEMORY ID 'MEM_ID'. But still it is throwing an error.

Can you please let me know how can I resolve this?

Regards,

Jyothi CH.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,100

Hi

You can provide the statement like this but here we are uploading the work area data means only one record

PROG:REPORT1.

DATA:E_ONE TYPE STRING.

EXPORT mem_id TO MEMORY ID 'E_ONE'.

In another report we can write below statment.

PROG:REPORT2.

data:E_ONE TYPE STRING.

IMPORT MEM_ID FROM MEMORY ID 'E_ONE'.

Regards,

muralii

7 REPLIES 7
Read only

Former Member
0 Likes
1,101

Hi

You can provide the statement like this but here we are uploading the work area data means only one record

PROG:REPORT1.

DATA:E_ONE TYPE STRING.

EXPORT mem_id TO MEMORY ID 'E_ONE'.

In another report we can write below statment.

PROG:REPORT2.

data:E_ONE TYPE STRING.

IMPORT MEM_ID FROM MEMORY ID 'E_ONE'.

Regards,

muralii

Read only

Former Member
0 Likes
1,100

Hi,

Can you please tell me what error are you getting after rectifying the EXPORT statement i.e.

EXPORT E_VBKOK XANZPK TEXTTAB XBOLNR TO MEMORY ID 'MEM_ID'.

Danish.

Read only

Former Member
0 Likes
1,100

Hi Danish,

Still I am getting the same syntax error.

Regards,

Jyothi CH.

Read only

0 Likes
1,100

Hi Jyoti,

You cannot get the same syntax error as you have changed the syntax from MEM_ID to 'MEM_ID'.

Please re-run the transaction and tell me the error once again.

Danish.

Read only

Former Member
0 Likes
1,100

what is the error from

EXPORT E_VBKOK XANZPK TEXTTAB XBOLNR TO MEMORY ID 'MEM_ID'.

In this case, four objects, whether single values, structures, tables or whatever, should have been exported to memory if they exist at the time of this export.

The simple way to do this is to define the same objects in both the exporting and importing program, then....

export object1 object2.... to memory id 'MEM_ID'.

import object1 object2....from memory id 'MEM_ID'.

Read only

Former Member
0 Likes
1,100

Hi Jyothi,

data: l_var type string.

concatenate '6' '8' into l_var separated by space.

export l_var to memory id 'BB'.

Here we have to declare the type(structure) for l_var not for BB

and in another program

data:l_var type string.

import l_var from memory id 'BB'.

write : l_var.

Read only

Former Member
0 Likes
1,100

Hi All,

I ahve changed to "MEM_ID' Now it is working fine. Thanks for your help.

Regards,

Jyothi CH.