How to get Technical Type of BOM

1
105
Technical Type of BOM
BOM Technical Type (RC29K-TETYP) is not directly saved in any table. We need to translate and determine the Technical Type. For this, we need to hit standard table STZU (Permanent BOM data) with STLTY (Item Category) and STLNR (BOM).
[adToAppearHere]
IF STZU-ALTST(Indicator: Alternative) is not blank, it means Technical Type is ‘M’ (multiple BOM).
IF STZU-VARST(Indicator: Variants) is not blank, it means Technical Type is ‘V’ (variant BOM).
Code snippet
      READ TABLE i_stzu INTO l_wa_stzu WITH KEY
       stlty = l_wa_stpo-item_categ
       stlnr = l_wa_stpo-bom_no
       BINARY SEARCH.
      IF sy-subrc EQ 0.
        IF l_wa_stzu-altst EQ abap_true.
          l_wa_ibom-tetyp = ‘M’. ” M
        ELSE.
          IF l_wa_stzu-varst EQ abap_true.
            l_wa_ibom-tetyp = ‘V’. “V
          ELSE.
            CLEAR l_wa_ibom-tetyp.
          ENDIF.
        ENDIF.
      ENDIF.

1 COMMENT

LEAVE A REPLY

Please enter your comment!
Please enter your name here