Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9236

Re: moving multiple fields in a single iternal table

$
0
0

Hi

 

You should check it with debug by yourself, anyweay a problem could be in FYSCAL YEAR: you don't use it,

MM document can be the same number in different yearts, so it's better to use fyscal yaer too:


 

 

SELECTbudat xblnr mblnr MJAHR

   FROM mkpf

    INTO CORRESPONDING FIELDS OF TABLE it_mkpf

      WHERE mblnr IN s_mblnr.

 

IF sy-subrc = 0.

   SELECT mblnr zeile bwart matnr lgort charg lifnr kunnr werks dmbtr menge meins  mjahr

         FROM mseg

          INTO CORRESPONDING FIELDS OF TABLE it_mseg

                 FOR ALL ENTRIES IN it_mkpf

                    WHERE mblnr = it_mkpf-mblnr

                        AND MJAHR = OT_MKPF-MJAHR.

 

 

read TABLE it_mkpf INTO WA_MKPFwith KEY mblnr = wa_mseg-mblnr.

read TABLE it_mkpf INTO WA_MKPFwith KEY mblnr = wa_mseg-mblnr.

                                                                    MJAHR = WE_MSEG-MJAHR,

            if sy-subrc = 0.

            move wa_mkpf-budat to wa_mseg2-budat .

            move wa_mkpf-xblnr  to wa_mseg2-xblnr.

            endif.

 

           ENDIF.


Max


Viewing all articles
Browse latest Browse all 9236

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>