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

import export in same program

Former Member
0 Likes
631

i have a counter when i call the prog again the counter is claer.

how i can i m make export import to get the old data.

1 ACCEPTED SOLUTION
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
580

You could use the EXPORT/IMPORT statement but you would need to write it to the shared buffer which is an extension of the EXPORT/IMPORT statements. Maybe it would be better to use a parameter id here using the SET and GET statements.

SET parameter id 'ZCOUNT' field v_count.


GET parameter id 'ZCOUNT' field v_count.

Regards,

RIch Heilman

3 REPLIES 3
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
581

You could use the EXPORT/IMPORT statement but you would need to write it to the shared buffer which is an extension of the EXPORT/IMPORT statements. Maybe it would be better to use a parameter id here using the SET and GET statements.

SET parameter id 'ZCOUNT' field v_count.


GET parameter id 'ZCOUNT' field v_count.

Regards,

RIch Heilman

Read only

0 Likes
580

i'm entering to prog itab_main is 3 line

and itab is 1 line and go out and entering to the prog again

i want to append to itab all the 3 lines--remember i going out and entering 3 times so it clear

DESCRIBE TABLE itab_main LINES zlin_tab.

itab--is always 1 line

DESCRIBE TABLE itab LINES zlin_tab.

GET parameter id 'ZCOUNT' field zlin_tab.

if zlin = zlin_tab. "to print pizul

SUBMIT ZWM_XXXX AND RETURN.

else.

zlin = zlin + 1.

SET parameter id 'ZCOUNT' field zlin_tab.

endif.

its not work heeelp

Read only

0 Likes
580

Not exactly sure of your requirement, but just before the SET statement, you are adding to ZLIN, is this correct? Shouldn't you be changing ZLIN_TAB?

zlin = zlin + 1.
SET parameter id 'ZCOUNT' field zlin_tab.

Also, these statements. when you describe you are filling ZLIN_TAB and when doing the GET, if there is not value in memory, then it will fill ZLIN_TAB with nothing and hence clear it out.

DESCRIBE TABLE itab LINES zlin_tab. 

GET parameter id 'ZCOUNT' field zlin_tab.

Regards,

RIch Heilman