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

Understanding the code

Former Member
0 Likes
580

Hi gurus, following code is in a pricing requirement, can some one explain me what is this doing as i do not understand clearly and pricing condition is not applied saying the following requirement is not fulfilled,

data: v_mara type mara.
  sy-subrc = 4.
   if komk-auart is initial.
      
    check: komk-fkart eq 'IV' or komk-bsart ne ' '.
    endif.
                        
    check: komk-auart ne 'cc' and komk-auart ne 're'.
    check: komk-auart_sd ne 'CC' and komk-auart_sd ne 'RE'.
   sy-subrc = 0.*
   select single * from mara into v_mara where matnr = komp-matnr.
   if sy-subrc = 0.

      sy-subrc = 4.
       check:  v_mara-mtart ne 'LEER' and v_mara-mtart ne 'ZPRE' and v_mara-mtart ne 'VEN'.
     sy-subrc = 0.

     if komk-auart_sd eq 'OR' or komk-auart_sd eq ' '.
       komp-zprodh3 = v_mara-prdha(3).
     endif.
   endif.

Thank you in advance,

Kind regards,

Gopio.

Edited by: Naga Gopathi on Apr 13, 2010 11:58 PM

Edited by: Matt on Apr 20, 2010 7:52 AM

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
505

In certain conditions (needs a good cleanup, I think), sets a customer field equal to the first three characters of the material product hierarchy value.

2 REPLIES 2
Read only

Former Member
0 Likes
506

In certain conditions (needs a good cleanup, I think), sets a customer field equal to the first three characters of the material product hierarchy value.

Read only

Former Member
0 Likes
505

thanks