Application Development 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: 

Import , Export problem in Internal table

Former Member
0 Kudos

Hi all,

I am using ver 4.6C.

I have 2 programs namely X an Y.

X is main program and Y is having some Internal table with data. I want to use Y internal table in X program.

In X program.

I used SUBmit to call Y program . After Submit I used Import as follows.

Import Itab from memory id 'ABC'.

In y program used Export as follows

Export itab from memory id 'ABC'.

When I put break-point and check ITAB in X program it is empty.

Anyone help me or send code will be appreciated.

Thanks

Rathnam

8 REPLIES 8

Former Member
0 Kudos

u can't export and import internal tables

so it will not work.

we can export only parameters and select-options only

<b>Reward Points If Useful</b>

Former Member
0 Kudos

A quick search on the forum returns the answer:

Please try and search the forums for a reply first.

Hope this helps.

Sudha

0 Kudos

Hi Sudha,

Is it working in ver 4.6C?

Thanks

Rathnam

0 Kudos

Dont know, are you facing any problems?

Sudha

Former Member
0 Kudos

Hi Stalin,

i did it the following way:

CONSTANTS: memid_zfo0consu_upl(13) TYPE c VALUE 'ZFO0CONSU_UPL'.

TYPES: BEGIN OF t_zfo0consu_upl,

zfo0consu type /bic/oizfo0consu.

TYPES: END OF t_zfo0consu_upl.

DATA: it_zfo0consu_upl TYPE STANDARD TABLE OF t_zfo0consu_upl

WITH DEFAULT KEY.

*&...Gesellschaft exportieren

EXPORT zfo0consu_upl = it_zfo0consu_upl TO MEMORY ID

memid_zfo0consu_upl.

and then the import.

CONSTANTS: memid_zfo0consu_upl(13) TYPE c VALUE 'ZFO0CONSU_UPL'.

DATA: BEGIN OF it_zfo0consu_upl OCCURS 0,

zfo0consu_upl TYPE /bic/oizfo0consu.

DATA: END OF it_zfo0consu_upl.

*&...Import der Upzuloadenden Gesellschaft

IMPORT zfo0consu_upl = it_zfo0consu_upl

FROM MEMORY ID memid_zfo0consu_upl.

<b>Reward if useful.</b>

Kind regards

Henner

former_member189059
Active Contributor
0 Kudos

hello,

use this syntax

DATA: wa_indx TYPE indx.

    EXPORT tab = itab TO DATABASE indx(xy) FROM wa_indx CLIENT
    sy-mandt
    ID 'DETAILLIST'.

and to get it back..


    IMPORT tab = itab FROM DATABASE indx(xy) TO wa_indx CLIENT sy-mandt
      ID 'DETAILLIST'.

note that itab must be declared in both programs with the same structure

varma_narayana
Active Contributor
0 Kudos

Hi...

There is a syntax problem in ur code. In the Submit statement use AND RETURN also. Use the ITAB[ ] to indicate the BODY otherwise it may use the header only.

Check this Example:

You can ABAP MEMORY (EXPORT , IMPORT) for this.

In the Report you have to use EXPORT to Transfer the Output Internal table to ABAP memory.

EXPORT MTAB FROM IT_OUTPUT[] TO MEMORY ID 'ABC'.

In the Called program you have to use IMPORT to Retreive the ITAB from ABAP MEMORY.

IMPORT MTAB TO IT_DATA[] FROM MEMORY ID 'ABC'.

<b>Reward if Helpful</b>

Former Member
0 Kudos

Hi All,

This is the scenario,

1. PO Cretaed in 2005 and the costcentre was 1122.

2. Blocked the cost centre 1122 in 2006. ( NO MORE USE)

3. carryforwarded the same PO in 2007 and manually change the costcentre from

1122 to 1123 in PO.

4. the problem is Committment item not carry forwarded , in the customize report the committement doesn't show the amount. I came to know that once carryforward PO , the commitment also carryforwarded (IF IT IS SAME COST CENTRE) . My case is diffrent cost centre, that's why commitment not carryforwarded.

5. The user don't want to cancel the PO .

PLS ANYONE HELP ME SOLVE THIS PROBLEM?

Thanks

Nathan