-------------------- -------------------- -------------------- -------

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
*&---------------------------------------------------------------------*
*& Report ZUNI_OVK_MM_ZUNI_IN_EX_AVIZO *
*& *
*&---------------------------------------------------------------------*
*& *
*& *
*&---------------------------------------------------------------------*
REPORT ZUNI_OVK_MM_ZUNI_IN_EX_AVIZO .
data
: l_memory_id type char30
, l_subrc type sysubrc
, l_rpo_doknr type doknr
, l_doknr type doknr
, l_mode type char1
.
parameters
: p_rdoknr type doknr
, p_doknr type doknr
, p_mode type char1
.
initialization.
"load-of-program.
start-of-selection.
l_rpo_doknr = p_rdoknr.
l_doknr = p_doknr.
"l_mode = p_mode.
if l_rpo_doknr is initial or l_doknr is initial.
exit.
endif.
case p_mode .
when '-'. move '1' to l_mode.
when '+'. move '2' to l_mode.
endcase.
call function 'ZUNI_INCLUDE_EXCLUDE_AVI'
exporting
i_mode = l_mode
i_rpo_doknr = l_rpo_doknr
i_doknr = l_doknr
importing
e_sysubrc = l_subrc
exceptions
mode = 1
others = 2
.
concatenate 'ZMOST'
sy-uname
into l_memory_id separated by '/'.
export l_subrc = l_subrc to database INDX(ST) id l_memory_id.