2021 May 14 12:00 PM
Hi
I have below Program but it does not display any data . Function Module display record.
In Parameter i am entering 000000000000000038
REPORT ZABAP_GETMATERIALDETAILS.
data : wa_mara type mara.
PARAMETERS : p_matnr type mara-matnr.
CALL FUNCTION 'ZABAP_GETMATERIALDETAILS'
EXPORTING
IM_MATNR = p_matnr
* IMPORTING
* EX_MARA = wa_mara
.
Write : SY-SUBRC.
IF SY-SUBRC = 0.
* Implement suitable error handling here
WRITE : WA_MARA-MATNR, WA_MARA-MTART, WA_MARA-MEINS, WA_MARA-MBRSH .
ENDIF.
FUNCTION ZABAP_GETMATERIALDETAILS.
*"----------------------------------------------------------------------
*"*"Local Interface:
*" IMPORTING
*" REFERENCE(IM_MATNR) TYPE MARA-MATNR
*" EXPORTING
*" REFERENCE(EX_MARA) TYPE MARA
*"----------------------------------------------------------------------
SELECT SINGLE * FROM MARA
INTO EX_MARA
WHERE MATNR = IM_MATNR.
ENDFUNCTION.
Thanks
2021 May 14 12:09 PM
Hello ramco_1917
You're not receiving any data back, because the IMPORTING part is commented out.
It is responsible for receiving data from the function.
Kind regards,It works better if you import the values
2021 May 14 12:03 PM
2021 May 14 12:09 PM
Hello ramco_1917
You're not receiving any data back, because the IMPORTING part is commented out.
It is responsible for receiving data from the function.
Kind regards,| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |