2008 Nov 11 11:32 AM
Hi
I got a requirement that in one case I have to delete a records from db
So I suppose to do like
Loop at itab.
Delete stko where IDNRK = it_itab1-matnr.
Endloop.
Is it suggestible for my requirement?
Please help me out
Thanks in Advance.
Regards
Rao
2008 Nov 11 1:28 PM
Hi,
You can create BDC or LSMW for CS02 transaction and delete the BOM.
In the second screeen MATERIAL BOM menu you have an option to delete the BOM.
You also require Change number for do this activity or you can request authoriztion to basis team
to delete BOM without change number.
Regards,
Shan
Hi,
You can create BDC or LSMW for CS02 transaction and delete the BOM.
In the second screeen MATERIAL BOM menu you have an option to delete the BOM.
You also require Change number for do this activity or you can request authoriztion to basis team
to delete BOM without change number.
Regards,
Shan
2008 Nov 11 11:41 AM
Its Not advisable to delete standard table records other than from standard transactions.
Regards
Karthik D
2008 Nov 11 11:42 AM
If you can tell us that why you want to delete the data from BOM Header table that will be more helpful. Because deleteing data in this way is not supported by SAP. A BDC can be a better option.
2008 Nov 11 11:43 AM
Hi
The standard tables are always inter related. So, you should check the consequences you would have to face.
Check where all this table is used, what is the effect it is going to take?
Also, check if the table is client independant or dependant.
Do some research about the table first and then delete.
Regards,
Vishwa.
2008 Nov 11 11:47 AM
i want to change the item category of BOM. its not possible to change the item category of BOM, so first i am deleting the item category aft tht i ll re-insert the item category again.
2008 Nov 11 11:52 AM
Your approach is not going to work in the way you are trying, i suppose you will end up crashing the system.
My suggestion is to do a BDC recording or BAPI to delete BOMs and then re-upload again with the correct Item category...
Regards
Karthik D
2008 Nov 11 11:54 AM
Hi Karthik
Can u tell me BAPI name or in BDC how we do for deleting
2008 Nov 11 1:22 PM
2008 Nov 11 1:34 PM
Hi,
see if u can use the BAPI 'CAVC_I_CHANGE_BOM_ITEM_DATA'.
Regards,
Nagaraj
2008 Nov 11 1:28 PM
Hi,
You can create BDC or LSMW for CS02 transaction and delete the BOM.
In the second screeen MATERIAL BOM menu you have an option to delete the BOM.
You also require Change number for do this activity or you can request authoriztion to basis team
to delete BOM without change number.
Regards,
Shan
2008 Nov 11 2:16 PM
Hi Shan
i want to delete the item category of BOM only not whole BOM, for deleting this we will use IB02 Tcode.
So can u give some idea for writing this program
Thanks in Advance.
2008 Nov 11 2:29 PM
Before writing a programmatically deleting records from a SAP standard Database table, consider this thread: This poor chap has at least not caused an business problems.
Now think about what you will do if your program doesn't quite work as expected, and you end up with a corrupted production system that means the business can no longer do their work.
2008 Nov 11 2:33 PM
i will delete in BOM Item Category only aft tht i ll update with new values in single program only i will do this.
2008 Nov 11 2:36 PM
Go ahead by all means and write your code.
And dont forget to put your experience afterwards when the executives and Audit come after you and your team for doing that
2008 Nov 11 2:38 PM
There could be all sorts of processing that has already taken place that depends on the bom item category. There's a reason it isn't changeable by SAP supplied transactions. When you do more processing using that bom, you could end up with inconsistencies. Are you sure you won't. 100%, bet your life sure?
Are you planning on running this in production?
2008 Nov 11 2:43 PM
Hi Matt
i am 100% sure that its my requirement only
its not possible to change item cateegory of BOM for tht we have to do delect that one aft tht i ll reinsert again in single program only
2008 Nov 11 2:44 PM
2008 Nov 11 2:45 PM
>
> Hi Matt
>
> i am 100% sure that its my requirement only
> its not possible to change item cateegory of BOM for tht we have to do delect that one aft tht i ll reinsert again in single program only
Then make 100% sure that you cover yourself as Ajay Tiwari says. When it goes wrong, if you've not pointed out the risks, you could be the scapegoat.
2008 Nov 12 4:45 AM
>
> Hi Matt
>
> i am 100% sure that its my requirement only
> its not possible to change item cateegory of BOM for tht we have to do delect that one aft tht i ll reinsert again in single program only
If you are 100% sure then instead of Delete & insert do Update.
Regards
Karthik D
2008 Nov 11 2:43 PM
Hi,
In the worst case, if you have to do this...make sure you document everything properly and take the nec essary approvals so as to save yourself in case a issue raised on the approach being followed.
Don't forgot to include the risk of this solution apporach in your formal documents, and approvals.
2008 Nov 12 4:49 AM
HI Rao,
You are trying to delete the record from STKO table with the key field.
please note that this IDNRK field along with its value is updated in many tables, so if you delete this way you end up with data inconsistency.
so please contact your FC to take required action not you as an ABAPER.
regards
Ramchander Rao.K
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |