Skip to Content
-1

Not able to Import the Data From the Enhancement point.

I have one problem,
need to export one structure from one place to another place.
While exporting data is getting in Structure, but while importing Structure is empty.

Export.

Data:BEGIN OF rit_mseg OCCURS 0.
INCLUDE STRUCTURE mseg.

data:END OF rit_mseg.

move: mseg to rit_mseg.
EXPORT MSEG TO MEMORY ID 'CTAB'.

Import
DATA:BEGIN OF rit_mseg1 OCCURS 0.

INCLUDE STRUCTURE mseg.
DATA:END OF rit_mseg1.

IMPORT rit_mseg TO rit_mseg1 FROM MEMORY ID 'CTAB'.
FREE MEMORY ID 'CTAB'.

Any suggestion about above problem.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Mar 14 at 06:14 AM

    Hello charan,

    For Import /export the names of variables should be same. Then only will import data.

    REPORT ztest.
    DATA mseg TYPE mseg.
    
    DATA:BEGIN OF rit_mseg OCCURS 0.
            INCLUDE STRUCTURE mseg.
    DATA:END OF rit_mseg.
    
    mseg-mblnr = '123' .
    
    * Export
    MOVE: mseg TO rit_mseg.
    EXPORT mseg TO MEMORY ID 'CTAB'.
    CLEAR mseg.
    
    
    *IMPORT
    DATA:BEGIN OF rit_mseg1 OCCURS 0.
            INCLUDE STRUCTURE mseg.
    DATA:END OF rit_mseg1.
    
    IMPORT mseg FROM MEMORY ID 'CTAB'.
    FREE MEMORY ID 'CTAB'.
    

    Thanks,

    Praveen.

    Add comment
    10|10000 characters needed characters exceeded