on 09-09-2011 12:44 PM
Hello,
I have already enhanced the Transaction DataSource using exit_saplrsap_001. Now there is new requirment to add one more field to the same Data Source and populate values for the filed.
I want to implement BADI for the same data source. Can we implement using BADI?
Need your suggestion and help for the same.
Regards,
Rajeev
Hi,
For using the BADI :
1) First of all you have to get the BADI Definition name i.e RSU5_SAPI_BADI.
2) Then we have to implement the BADI using TCODE SE19
3) Follow proper naming convetions for the impementation name suppose /KHE/ZBW_IMPL
4) A Class is created automatically i.e /KHE/CL_IM_ZBW_IMPL
5) Go to the method DATA_TRANSFORM by double clicking
6) inside the method write the following code
CASE i_datasource.
WHEN 'DATASOURCENAME'.
write your required logic to enhance the datasource
endcase.
7) activate the BADI
😎 Once you run the datasource it will trigger the BADI internally and datasouce will be enhanced.
Please let me know if you getting any issues.
Thanks,
Rajesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
1) Go to function module exit e EXIT_SAPLRSAP_001
2) Double click on the include ZXRSAU01
3) WHEN 'Datasource_Name'.
PERFORM Zdatasource TABLES C_T_DATA[].
4)Double click on the perform and write the code in the FORM.
5)FORM Zdatasource TABLES l_data STRUCTURE (Provide the structure name used in the datasource).
6) Decalare structure like
DATA: st_zox003 LIKE zox003,
l_tabix LIKE sy-tabix .
LOOP AT l_data INTO st_zox003.
l_tabix = sy-tabix.
put your logic regarding enhancement
MODIFY l_data FROM st_zox003 INDEX l_tabix.
endloop.
Do let me know if you require any further help.
Thanks,
Rajesh
HI Rajeev,
You can definitely enhance the data source using BADI.
As of SAP_BASIS 6.20 and PI_BASIS 2004_1 (R/3 Release 4.6C) is available a more efficient way to enhance SAP standard content, using Business Add-Ins (BAdIs) rather than user exits.
The technical name of this BAdI is RSU5_SAPI_BADI, detailed on the SAP Note 691154.
This will ease the pressure of transporting the common Include program which will be carrying codes affecting multiple data sources.
Using this badi you just have to transport the BADI without bothering about the user exit.
Please go through the below link, it will really help you -
[http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/3001894b-b1fb-2910-77ba-e80b6f2053b7?QuickLink=index&overridelayout=true]
Hope this helps.
Regards,
RahulM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
U can add the field in the same append structure or new append structure . usually it is followed if the earlier structure was created by some other developer and has already been transported , we create a new structure to avoid confusions .
However this is totally dependant on the conventions followed , makes no difference to proceed with either of the scenarios .
Thanks ,
Devraj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
May help you:----
http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/80e32c8b-3d2d-2e10-2795-9e251437f8ee
Regards,
Suman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Check the below article for enhancing data source using BADI,
[http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/3001894b-b1fb-2910-77ba-e80b6f2053b7?QuickLink=index&overridelayout=true]
But why don't you add logic for new field in the EXIT itself and use it in data source.
Regards,
Durgesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.