cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

End Routine Syntax Error

Former Member
0 Likes
448

Hi Experts,

In my requirement i have to populate BILL_DATE from DSO table (ZSC_O0600),

key fields are: BILL_NUM

and BILL_ITEM

I am populating BILL_DATE into ZORIGIND

where BILL_NUM = ZSUBDOCN

BILL_ITEM =ZSUBDOCI

I am getting syntax error

E: No Component EXISTS WITH THE NAME "bill". "bill".

I declared the type but still coming.

Please check the code and recommend what can do.

Thanks

Pawan

View Entire Topic
Former Member
0 Likes

Hi,

For Reference below code. Lookup the 3 fields data while updated to target.

data wa_RESULT_PACKAGE type _ty_s_TG_1,

           lt_lookup type table of ty_lookup,

           wa_lookup type ty_lookup,

           lv_tabix type sy-tabix.

      BREAK-POINT.

*            read table RESULT_PACKAGE into wa_result_package index 1.

       if RESULT_PACKAGE is not initial.

          select material distr_chan PROV_GROUP REBATE_GRP MAT_KONDM

            from /BIC/AZDSO_MGR00

            into table lt_lookup

             for all entries in RESULT_PACKAGE

           where MATERIAL = RESULT_PACKAGE-MATERIAL

             and DISTR_CHAN = RESULT_PACKAGE-DISTR_CHAN.

          if sy-subrc = 0.

            sort lt_lookup by material distr_chan.

            loop at RESULT_PACKAGE into wa_RESULT_PACKAGE.

              lv_tabix = sy-tabix.

              read table lt_lookup into wa_lookup with key

                   MATERIAL = wa_RESULT_PACKAGE-MATERIAL

                 DISTR_CHAN = wa_RESULT_PACKAGE-DISTR_CHAN binary search.

              if sy-subrc = 0.

                wa_RESULT_PACKAGE-PROV_GROUP = wa_lookup-PROV_GROUP.

                wa_RESULT_PACKAGE-REBATE_GRP = wa_lookup-REBATE_GRP.

                wa_RESULT_PACKAGE-MAT_KONDM = wa_lookup-MAT_KONDM.

              modify RESULT_PACKAGE index lv_tabix from wa_RESULT_PACKAGE

                 transporting PROV_GROUP REBATE_GRP MAT_KONDM .

              endif.

             endloop.

   endif.

  endif.

Thanks,

Srinu.Rapolu