cancel
Showing results for 
Search instead for 
Did you mean: 

CoGs (Cost of goods sold) comes zero in billing doc ?

Former Member
0 Kudos

Hi Gurus,

Could you please advise me why CoGs comes zero cost , but sales price comes perfect ? This is happening for Internal customers only where they are costplus type customers ..?

It is working perfect for standard customers ...

Could you please throw some light on this issue ?

Kind Regards
Rama

Accepted Solutions (1)

Accepted Solutions (1)

jignesh_mehta3
Active Contributor
0 Kudos

Hello Rama,

COGS is determined in Delivery & not in Billing Doucment.

Can you please explin our business process in detail. Also ou have mentioned that VPRS is not present in Invoice for Internal Customers. Which means there are separate Pricing Procedures for different types of Sales.

Thanks,

Jignesh Mehta

Former Member
0 Kudos

Hi ,

Both are having different pricing procedure ...

see attached billing screens ,..

VPRS is in standard , not on internal customers .I beleive that is why cogs is zero for internal customers ...please confirm

former_member184065
Active Contributor
0 Kudos

Dear,

I am unable to see exactly ,what is the Problem in this .Please explain in detail .

Thanks,

Naren

Former Member
0 Kudos

HI ,

I am getting costs of goods sold as zero price in billing doc (vbrp-wavwr) for non-standard customers ...

for standard customers it is coming perfect in billing doc .. first one is non-std , secod one is std  where you can VPRS in std , which is not in non-std one ...

regards

Rama

former_member184065
Active Contributor
0 Kudos

Dear,

I have some doubts on this .Please let me know below queries to answers .

1. Is that Pricing Procedure having VPRS condition type  ( non Standard customers ) ?

2. Did you get that VPRS cost in Sales Order level in condition tab level ?

Please let me know .

Thanks,

Naren

Former Member
0 Kudos

Hi,

1.  Pricing procedure for std customers - Having VPRS .

     pricing proc for Non-std customers - Not having VPRS..

2.  No idea , but billing doc COSTS field having the same value as VPRS value in for std customers ..

where as NOn-std customers billing CoGs Costs is ZERO ...

Regards

Rama

former_member184065
Active Contributor
0 Kudos

Dear,

Fine .Now coming to the point is ,You dont have that VPRS condition Type for Non Standard customers ( in pricing Procedure ) thats why you were not getting that into Billing level .If you use that condition Type in Pricing Procedure then It should be come into Billing level .

Without VPRS condition Type in V/08 ,how can we get that into Billing level ?

Not possible .So ,we need to maintain it in V/08 .

If you have any doubts please let me know .

Thanks,

Naren

Former Member
0 Kudos

HI ,

Thanks ,

I am not getting the cost of goods sold for BoM material ...

Is there a way to acheive ...that ? its coming zero for BoM ...

Regards

Rama

Former Member
0 Kudos

Hi ,

For BoM material particluar VPRS which I  set it up  for non-standard customer showing an error ..

Could you pls advise me why ..?

Regardsd

Rama

former_member184065
Active Contributor
0 Kudos

Dear,

For BoM material particluar VPRS which I  set it up  for non-standard customer showing an error ..

Could you pls advise me why ..?

Please let me know ,what is the Error you are facing ?

Note : If you maintain Standard Price or Moving Average Price in Materials Master ( MM01 or MM02 ) for that Materials then We will get that Costs automatically in Sales Order level .

Thanks,

Naren

Answers (4)

Answers (4)

moazzam_ali
Active Contributor
0 Kudos

Hi

For BOM material please tell me is it main item? I mean are you looking for VPRS of main item or sub item or do you want cost of sub items transferred to main item? If possible please paste the screenshot of condition tab analysis screen of VPRS condition. It will help us to understand the issue.

If you want to transfer cost of sub items to main item then you can do this in copy control from delivery to billing at item level. There is an option which you can see there.

Thank$

Former Member
0 Kudos

HI ,

Thanks

I resolved it throwugh Formula routine ..

Thanks

Rama

former_member184065
Active Contributor
0 Kudos

Dear,

Could you please share that which Routine Formula ,you have used and where you have used .

Is it in V/08 for VPRS as 4 Routine -Cost ?

Thanks,

Naren

Former Member
0 Kudos

Hi ,

VOFM - Formula - condition value - New Routine added  & activated

V/08 - CalTYpe - added that routine here ...

Testing few more scenarios currently ..

Regards

Rama

Former Member
0 Kudos

Hi Ram,

I think finally you got closed this issue.

Could you please Share How you resolved this issue.

Which routine u used and what was the logic behind.

Regards,

Ranga

Former Member
0 Kudos

HI Ranga ,

We have two PP ..

Z1 - Standard customer   - It has VPRS in it .

Z2 - Internal customer ...  - It was not having VPRS in it .

So just added VPRS (copy of VPRS ) in Z2 PP ... and aunder CalTY have added a routine..

Routine logica is basicall to identify bactch price ..below is the logic..

check komp-zzvbtyp = 'J'.



select single mtart prdha into (lv_mtart, lv_prodh) from mara


                     where matnr = komp-matnr.



if sy-subrc eq 0      and


    lv_mtart eq 'ZSBM' and


    komp-zzbtchval is initial.


*    komp-zzvbtyp = 'J'.





    select vbap~vbeln


           vbap~posnr


           vbap~matnr


           vbap~prodh mara~mtart into table it_vbap


          from vbap


          inner join mara on


          mara~matnr = vbap~matnr


          where vbeln = komp-aubel and


                prodh = lv_prodh.


    sort it_vbap  by vbeln posnr mtart .


*    read table it_vbap into wa_vbap with key mtart = 'ZSBM'.


*    delete it_vbap where prodh ne wa_vbap-prodh.





   select vbelv posnv rfwrt into table it_vbfa


        from vbfa


        for all entries in it_vbap


       where vbelv = komp-vgbel


         and VBTYP_N = 'R'


         and posnv   = it_vbap-posnr.



      if not it_vbfa is initial.


        sort it_vbfa by vbelv posnv.


        loop at it_vbfa into wa_vbfa .


          lv_btchval = lv_btchval + wa_vbfa-rfwrt.


        endloop.


   komp-zzbtchval = lv_btchval.


endif.


endif.



*if  komp-zzvbtyp = 'J'.



* we are in a delivery


  xkwert = komp-zzbtchval.


CALL FUNCTION 'Z_CALCULATE'


  EXPORTING


    operand1       = komp-zzbtchval


    operand2       = komp-kpein


    operator       = '*'


IMPORTING


   RESULT         = lv_unit_cost


          .


CALL FUNCTION 'Z_CALCULATE'


  EXPORTING


    operand1       = lv_unit_cost


    operand2       = komp-mglme


    operator       = '/'


IMPORTING


   RESULT         = lv_unit_cost


          .


  xkomv-kbetr = lv_unit_cost.


*endif.

Hope it helps..

Kind regards

Rama

Former Member
0 Kudos

Hi Narendra ,

I had to create new cond type which will carry only the diffrenece between sales price and cost of good sold. This will have to trigger only during billing ...

How do I achieve that ..

They need this since its needed for their reporting at CO-PA

Appreciate your help..

KR

Rama..

former_member184065
Active Contributor
0 Kudos

Dear,

Create one Condition Type and maintain it in V/08 to fetch the value from sales price to COGS value then go to transaction KE4I and maintain condition type over here to carry that value to COPA.

If you have any doubts please let me know.

Thanks,

Naren

moazzam_ali
Active Contributor
0 Kudos

Hi

Please confirm are you using same pricing procedure and condition type for both processes?

If possible share the screens of condition tab of billing document.

Thank$

Former Member
0 Kudos

Hi ,

Both are having different pricing procedure ... I have attached condition screen of standard and non-standard customer ...at below ...

Regards

Rama

former_member186385
Active Contributor
0 Kudos

Hi Siva,

I guess this is enhancement, because as per standard COGS will not populate during Billing

so please check with your abaper if there is a code to restrict this to populate only for standard customers

regards,

santosh

Former Member
0 Kudos

Hi

Thanks

ANy idea which routine or enhancement ? looks like there are some enhancements done ..but not sure ...

Pls advise..

Thanks

Rama

suman_sardar2
Active Contributor
0 Kudos

Hi Rama,

Can you share your Billing pricing screen?

Is it same condition type (VPRS) used everywhere?

What is "Internal customers only where they are costplus type customers ..?"

Please clarify the above issues.

Thanks,

Suman$

Former Member
0 Kudos

Hi ,

Thanks

VPRS is in there only for standard customers , not internal customers ..

Regards

Rama

Former Member
0 Kudos

Hi ,

Both are having different pricing procedure ...

see attached billing screens ,..

VPRS is in standard , not on internal customers .I beleive that is why cogs is zero for internal customers ...please confirm