cancel
Showing results for 
Search instead for 
Did you mean: 

user exit

Former Member
0 Kudos

hi all,

i have a problem with new field add to MC03BF0.

these are the step that i do

1) i have enhanced the extract structure MC03BF0 with the append structure that contains new fields zzxblnr and zzprodh via TCODE SE11 (is correct? the RSA6 don't permit the enhancing of the structure MC03BF0).

2) after i have modified the EXIT_SAPLRSAP_001 with the code below via TCODE CMOD

<i>DATA: l_mc03bf0 LIKE mc03bf0.

DATA: l_index LIKE sy-index .

DATA: l_zzxblnr LIKE mc03bf0-zzxblnr.

DATA: l_zzprodh LIKE mc03bf0-zzprodh.

CASE I_ISOURCE.

WHEN '2LIS_O3_BF'.

BREAK-POINT.

clear l_index.

LOOP AT c_t_data INTO l_mc03bf0.

l_index = sy-tabix .

SELECT SINGLE xabln

FROM mkpf

INTO l_zzxblnr

WHERE mblnr = l_mc03bf0-mblnr

AND mjahr = l_mc03bf0-mjahr.

IF sy-subrc = 0 .

l_mc03bf0-zzxblnr = l_zzxblnr.

MODIFY c_t_data FROM l_mc03bf0 INDEX l_index .

ENDIF .

SELECT SINGLE prdha

FROM mara

INTO l_zzprodh

WHERE matnr = l_mc03bf0-matnr.

IF sy-subrc = 0 .

l_mc03bf0-zzprodh = l_zzprodh.

MODIFY c_t_data FROM l_mc03bf0 INDEX l_index .

ENDIF .

ENDLOOP.

        • fine mod. LG 10062006

WHEN OTHERS.

EXIT.

ENDCASE.

        • fine mod. LG 11062006</i>

3) i have tested the extractor with RSA3 and i have verify that the new field are not pupulated during the extraction process.

4) in debug mode i have verify that the program flow don't

come in the CASE statement

is the program that i write correct?

please help me

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

try: <b>CASE i_datasource</b>

/manfred

Former Member
0 Kudos

Hi,

in addition to Manfred's explanation: did you check if the fields are available in rsa6 now? May be you need to update table roosfield and set the field selection to space for your newly added fields.

regards

Siggi

Former Member
0 Kudos

the fields are in the ROOSFIELD table and i can view them with RSA6

edwin_harpino
Active Contributor
0 Kudos

hi Luigi,

CASE I_ISOURCE.

WHEN '2LIS_O3_BF'.

as mentioned should i_datasource.

and WHEN '2LIS_03_BF'.

0-zero instead of O.

i_isource is infosource,

you can check the parameter with se37, type in function module EXIT_SAPLRSAP_001 tab 'import'.

also try cmod de-activate and activate again the project.

hope this helps.

Former Member
0 Kudos

thanks

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Luigi,

For sample code, see the below link..

1. User Exits in SAP BW (ppt)

https://websmp104.sap-ag.de/~sapidb/011000358700005475091999

2. User Exits Code Examples (doc)

https://websmp104.sap-ag.de/~sapidb/011000358700005475101999

Hope it Helps

Srini

Former Member
0 Kudos

U mean in rsa6,the append structure add button does not work for this datasource?

I think I_ISOURCE points to the infosource.U need to check the datasource.Check parameters in the std include in CMOD.I think it is DATA_SOURCE.

Instead of break-point statement hard coded,set a break point by using the option present in menus(there is also shortcut to set this.dont remember it).also u can use 'stop' button to set break point when u run code in debug mode.

Instead of 2 modify statements,use a single modify statements(set flags during assignment to work-area and check flags later at end while modifying c_t_data from work area record).

I think using case I_ISOURCE is causing the main problem..

cheers,

Vishvesh

Former Member
0 Kudos

correction..use I_DATASOURCE as suggested by Manfred.

cheers,

Vishvesh

Former Member
0 Kudos

why i can't use I_ISOURCE, isn't a importing parameter for the exit?

Former Member
0 Kudos

yes I_ISOURCE is a import parameter,but here the user-exit should run for each of the the relevant datasources ONLY and not depending on the infosources.

cheers,

Vishvesh