cancel
Showing results for 
Search instead for 
Did you mean: 

Production Order Costs Breakup

Former Member
0 Kudos

Hi all,

I am trying to get the production order costs (CO03>Goto>Costs-->Cost comp. Structure). This displays the various costs (Overall, variable and fixed) for different cost components (material, Labour etc).

My question is; where can I find this data. I have tried the following:

1. Debugging the transaction and it uses a lot of CK_F* modules but cannot replicate the data in my owm program as the function modules seem to be pulling data populated elsewhere into the data structures of the function group.

2. Selecting data from COSS & COSP and indeed most of the CO* tables. The issue is that there does not seem to be any consistency in the fields in which SAP stores the costs in COSS and COSP. The selection works for some order s and not for others.

2a. There are also some orders which dont have an entry in COSS and/or COSP or any CO* tables or MCKALKW table which is also something I have tried; but the transaction CO03 still shows the cost breakup for the same.

If anyone has extracted all the costs of a production

order, could they please share their experience?

I am not very familiar with PP; in fact this is probably just the second/third program I have written in PP. So I dont have much idea of the process flow.

Any help will be highly appreciated. I dont want to sound desparate but will be very grateful for a straight-forward answer at present as I am under pressure to complete this requirement.

Regards,

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Try using mseg and supply production order number in your query .......

By doing all plus and minus (H/S) you will get total cost of production order , and if you dont require total cost then i am sure that you will find some fields which will allow you to calculate breakups.

Former Member
0 Kudos

Hi Sudhindra,

I had a look at the tables you mentioned and they dont seem to contain any data ... Do you know if the place where data is stored is related to some config parameters? The issue is that there is no functional consultant here who I can turn to.

Also.. would it be possible to mail the function module code to me? You can remove whatever code you feel is not for distribution and give me only the specific logic. My email is preet_dsouza@yahoo.com.

Although this may seem like a lazy option, I am really really under pressure for this to be completed and need some serious help which is why I am asking.

I did go through the standard CK_F* function module which the CO03 transaction uses but they seem to rely on various internal tables defined and filled at some point during th e transaction so what happens is that a function module "C" is the one which displays the report but it is already filled somewhere (cant tell where) by function modules "A" & "B" in the transaction.

Thanks for your help so far.. its much more than I have received at any other site.. but I would request you to please help me out some more this time.

Regards,

Preet

Former Member
0 Kudos

Hi Nimesh,

The amount of data in MSEG is HUGE.. searching on it for production order number which is a non primary key gives a timeout error in the ABAP program.

Is there any other way you feel that this can be done?

Thanks and regards,

Preet

Former Member
0 Kudos

Hi all,

Any ideas on how to get the material costs only for a production order. I would be able to settle for that only since it seems to be almost impossible to get the same data SAP is getting.

If I go the MSEG route is there anything special to keep in mind or is it only +/- DMBTR based on the debit/credit indicator?

Thanks and regards,

Preet

Former Member
0 Kudos

Hello,

Apologies for bringing this up again but the fact that at least I have got an answer to this post in this forum makes me hopeful. Also I didnt want to start a duplicate post.

Please can someone tell me how to find out CONSISTENTLY the production order costs. In CO03 going to the menu path GOTO->COSTS->COSTS COMP. STRUCTURE, one gets a list of the various costs in the production order. Now in one of my reports, this cost has to be captured as Materials Order costs and the total production costs (material + all other costs).

I just need these values for one field in my report. For this I have spent nearly a month and posted on all the discussion groups that I could find but with no one even replying. At least on this site someone has replied.

So.. can anyone please please help me.. I know I'm sounding desparate but that is only because I am. I just cannot understnd the logic that SAP is using and I do not have any functional consultant to go to for help.

Once again I request all of you on the SDN forums, please do try to help me out.

I am not trying for a quick fix solution ( although I will be extremely grateful for that) but at least some guidance. Please see my above posts for the difficulties I am facing. In short they are:

1. Production order which do not have entries in either COSS/COSP, MCKALKW or any of the other costing/PP tables that I could find except of course AFKO/AFPO.

2. No consistent way of storing the costs of the production orders. What I mean is that in COSS/COSP, the costs seem to be randomly stored in the fields from WEGO* in COSP and it is basically by reverse logic that I have built up the selection logic.

3. The functions CK_F* in the main are what SAP Seems to use for getting production costs but these function modules are very deeply complex, filling up various internal tables during some other process and are (for me at least) very difficult to debug.

Please someone help me out. Thanks for reading through this long rant but I truly am getting desparate.

Former Member
0 Kudos

Hi Preet,

I had done a report for costing which was a Production cost Analysis which had data to be picked up for the Overhead, Labour and Material. The tables that we were using for these purposes were CKMLHD and CKMLCR, try to get some data for these. Also one of my collegues had written a function module that could calculate the MLO breakup for a production order depending on the type of material. I'll try to get that if possible.

Regards,

Sudhi

Former Member
0 Kudos

Hi Sudhindra,

Thanks for the reply. I will have a look at the tables you have mentioned.

If you could help me with the function module, I will be very grateful.

Thanks in advance,

Preet

Former Member
0 Kudos

Also I have been searching online for some answer to the above question for nearly a week but havent been able to do so. The material & total order cost (materiallabouroverhead) is just a single field required in a larger report involving sales order, material and production order data...I am only stuck very badly on the production order costs data selection.