0% found this document useful (0 votes)
18 views

Structures

The document is an ABAP report that retrieves plant data for a specified material number from June. It defines a structure to hold the retrieved data and declares corresponding data objects. The report accepts a material number parameter, then queries several tables to retrieve the material description, plant, and plant description based on the material number. It writes the retrieved values to the output.

Uploaded by

hhfddn
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views

Structures

The document is an ABAP report that retrieves plant data for a specified material number from June. It defines a structure to hold the retrieved data and declares corresponding data objects. The report accepts a material number parameter, then queries several tables to retrieve the material description, plant, and plant description based on the material number. It writes the retrieved values to the output.

Uploaded by

hhfddn
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

*&---------------------------------------------------------------------* *& Report ZDEMO_JUNE_PLANT_DATA *& *&---------------------------------------------------------------------* *& *& *&---------------------------------------------------------------------* REPORT ZDEMO_JUNE_PLANT_DATA.

TYPES : BEGIN OF ty_marc, matnr TYPE matnr, werks TYPE werks_d, END OF ty_marc. DATA : wa_marc TYPE ty_marc. DATA : v_maktx TYPE maktx, v_name1 TYPE name1. PARAMETERS : P_matnr TYPE matnr. WRITE : /5 'Material', 30 'Materia Desc', 50 'Plant', 70 'Plant Desc'. SELECT single maktx from makt into v_maktx WHERE matnr eq p_matnr and spras e q sy-langu. SELECT matnr werks FROM marc INTO wa_marc WHERE matnr eq p_matnr. SELECT single name1 from t001w INTO v_name1 WHERE werks eq wa_marc-werks. WRITE : /5 wa_marc-matnr, 30 v_maktx, 50 wa_marc-werks, 70 v_name1. ENDSELECT.

REPORT

Z_NAZIA_STRUCTURES3.

TYPES : BEGIN OF wa_marc, matnr TYPE matnr, werks TYPE werks_d, v_maktx TYPE maktx, v_name1 TYPE name1, END OF wa_marc.

Data :

wa_marc TYPE wa_marc, matnr TYPE matnr, werks TYPE werks_d, v_maktx TYPE maktx, v_name1 TYPE name1.

*DATA : wa_marc TYPE ty_marc. **DATA : v_maktx TYPE maktx, ** v_name1 TYPE name1. PARAMETERS : P_matnr TYPE matnr. WRITE : /5 'Material', 30 'Materia Desc', 50 'Plant', 70 'Plant Desc'. SELECT single maktx from makt into v_maktx WHERE matnr eq p_matnr and spras e q sy-langu. SELECT matnr werks FROM marc INTO wa_marc WHERE matnr eq p_matnr. SELECT single name1 from t001w INTO v_name1 WHERE werks eq wa_marc-werks. WRITE : /5 wa_marc-matnr, 30 v_maktx, 50 wa_marc-werks, 70 v_name1. ENDSELECT.

You might also like