Skip to Content
0

how to get plant value while using customized screen on material master

May 23, 2017 at 03:55 AM

52

avatar image

I want to add customized fields on material master, I already make all settings on client level,I mean only set matnr as the unique key field .And it works. But I want it to be on plant level. So I set werks as another key field. But when the program goes through the function group I created ,it can not get the plant value from parameter ID WRK. So how can I get werks's value.Can anyone help me?Thanks.

The codes on that function group are as follows:

MODULE GET_DATA OUTPUT.
TABLES:ZPARTAPPEND.
DATA: W_MATNR TYPE MATNR.

IF SY-TCODE = 'MM02' OR SY-TCODE = 'MM03'.
GET PARAMETER ID 'MAT' FIELD W_MATNR.
SELECT SINGLE * FROM ZPARTAPPEND WHERE MATNR = W_MATNR.

ENDIF.

ENDMODULE. " GET_DATA OUTPUT

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

hong pan May 23, 2017 at 05:06 AM
0

MODULE get_data OUTPUT.
TABLES:zmat_cust_field.
DATA: w_matnr TYPE matnr.
DATA: w_werks TYPE werks_d.
IF sy-tcode = 'MM02' OR sy-tcode = 'MM03'.
GET PARAMETER ID 'MAT' FIELD w_matnr.
GET PARAMETER ID 'WRK' FIELD w_werks.
SELECT SINGLE * FROM zmat_cust_field WHERE matnr = w_matnr AND werks = w_werks.
ENDIF.

ENDMODULE. " GET_DATA OUTPUT

Share
10 |10000 characters needed characters left characters exceeded
Raymond Giuseppi
May 23, 2017 at 11:22 AM
0

Did you use 44410 - Integrating customer-specific fields in the material master to create your dynpro(s) If no could you describe first your process?

Share
10 |10000 characters needed characters left characters exceeded