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

Data deletion

Former Member
0 Likes
789

Hi all,

I have one object to delete  BOM data from standard SAP tables. User has provided me the txt file of all the material numbers to be deleted.

Whats the best way to do it? How can I handle the foreign key relationship of material?

Any suggestions will be helpful.

Thanks,

J

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
752

Hello J Singh,

The best way to delete the BOM using ABAP program is to use BAPI.

'CSAP_MAT_BOM_DELETE' use this BAPI to delete the BOM.

You have to paas only Material No. and BOM usage as import parameter.

You can load text file contains Material no into internal table in abap program. Then loop that internal table and delete one by one material bom. 

3 REPLIES 3
Read only

kesavadas_thekkillath
Active Contributor
0 Likes
752

In SCN search for the function module to delete the BOM. It has been discussed many times.

Read only

Former Member
0 Likes
753

Hello J Singh,

The best way to delete the BOM using ABAP program is to use BAPI.

'CSAP_MAT_BOM_DELETE' use this BAPI to delete the BOM.

You have to paas only Material No. and BOM usage as import parameter.

You can load text file contains Material no into internal table in abap program. Then loop that internal table and delete one by one material bom. 

Read only

0 Likes
752

Thank you Dhiraj.