2005 Sep 08 12:32 PM
Hi all,
I am new to SAP. My task is
In IDOC MATMAS I want to send MAKTX first and then I have to trigger IDOC again 2nd time to pass value MATNR in MAKTX. I know it is confusing... We have MATNR which is defines as 25 length. So, we have added new field with length 25. Task is I want to send this field in place of MAKTX.
How to do it.
very urgent.
Many Thanks;
shashikanth
Hi Shashikanth,
I think your requirement is to send both Material number and Material Description.
If that is the case, then why don't you send Material Description in MAKTX and send the material number in some other unused field like WRKST_NEW (length=40) of segment E2MARAM004.
I think this would be a better solution that re-triggering the idoc.
Regards,
Urmila
2005 Sep 08 1:37 PM
Hi Shashikanth,
I think your requirement is to send both Material number and Material Description.
If that is the case, then why don't you send Material Description in MAKTX and send the material number in some other unused field like WRKST_NEW (length=40) of segment E2MARAM004.
I think this would be a better solution that re-triggering the idoc.
Regards,
Urmila
2005 Sep 08 1:53 PM
Thanks Urmila,
I am very confused.... I am new to SAP.
Where can I find triggering program for IDOC MATMAS which is already written in my system. I am searching for that.
One told ne to go to partners system so that i can find fprogram but i couldnt.
Pls let me know;
Many thanks;
shashikanth
2005 Sep 08 2:33 PM
Hi Shashikant,
Go to transaction BD60 and look for Message type MATMAS. Look at the deatils. The corresponding FM is MASTERIDOC_CREATE_SMD_MATMAS.
Regards,
Urmila
2005 Sep 08 2:43 PM
2005 Sep 08 3:16 PM
Hi Shashikant,
The FM that you use for processing the IDOC depends on whether you are sending the IDOC to an external system (Outbound Processing) or posting the IDOC in your system (Internal processing).
Outbound Processing: FM MASTERIDOC_CREATE_SMD_MATMAS
Inbound Processing:IDOC_INPUT_MATMAS01
Regards,
Urmila
2005 Sep 08 3:39 PM
Hello Urmila,
I am sending IDOC to an external system.
Is it same Function module for all idoc matmas.
Thanks.
shashikanth
2005 Sep 08 6:30 PM
Use Transaction BD10 for sending MATMAS. However your requirement is a very confusing, because MATMAS is fully capable of sending material number as well as material description at the same time. I suggest you clarify that first, it will only save your time.
Cheers,
Sanjeev
2005 Sep 09 11:19 AM
hello urmila,
The idea u gave me is really working(using wrkst_new).
This is code i have developed
READ TABLE IDOC_DATA WHERE SEGNAM = E1MARAM.
IF SY-SUBRC = 0.
IF SEGMENT_NAME = E1MARAM.
E1MARAM-WRKST_NEW = F_MARA-YYMATNR.
MODIFY IDOC_DATA INDEX TABIX.
ENDIF.
ENDIF.
But i dont know where to add above code?
Where should i add this in below program?
Reference to interface for local BAdI ...
DATA: local TYPE REF TO /SIE/SSG_MGV00001_L_IF,
l_actimp type C.
Create object instance for local BAdI ...
CALL METHOD cl_exithandler=>get_instance
IMPORTING
ACT_IMP_EXISTING = l_actimp
CHANGING
instance = local.
if l_actimp = 'X'.
call method for local implementation
CALL METHOD local->EXIT_SAPLMV01_002_B000
EXPORTING
MESSAGE_TYPE = MESSAGE_TYPE
SEGMENT_NAME = SEGMENT_NAME
F_MARA = F_MARA
F_MAKT = F_MAKT
F_MARC = F_MARC
F_MARD = F_MARD
F_MFHM = F_MFHM
F_MPGD = F_MPGD
F_MPOP = F_MPOP
F_MPRW = F_MPRW
F_MVEG = F_MVEG
F_MVEU = F_MVEU
F_MKAL = F_MKAL
F_MARM = F_MARM
F_MEAN = F_MEAN
F_MBEW = F_MBEW
F_MLGN = F_MLGN
F_MVKE = F_MVKE
F_MLAN = F_MLAN
IMPORTING
IDOC_CIMTYPE = IDOC_CIMTYPE
CHANGING
*{ REPLACE GMMK901260 1
*\ IDOC_DATA = IDOC_DATA
IDOC_DATA = IDOC_DATA[]
*} REPLACE
.
endif.
if l_actimp = 'X'.
call method for local implementation
CALL METHOD local->EXIT_SAPLMV01_002_E999
EXPORTING
MESSAGE_TYPE = MESSAGE_TYPE
SEGMENT_NAME = SEGMENT_NAME
F_MARA = F_MARA
F_MAKT = F_MAKT
F_MARC = F_MARC
F_MARD = F_MARD
F_MFHM = F_MFHM
F_MPGD = F_MPGD
F_MPOP = F_MPOP
F_MPRW = F_MPRW
F_MVEG = F_MVEG
F_MVEU = F_MVEU
F_MKAL = F_MKAL
F_MARM = F_MARM
F_MEAN = F_MEAN
F_MBEW = F_MBEW
F_MLGN = F_MLGN
F_MVKE = F_MVKE
F_MLAN = F_MLAN
IMPORTING
IDOC_CIMTYPE = IDOC_CIMTYPE
CHANGING
*{ REPLACE GMMK901260 2
*\ IDOC_DATA = IDOC_DATA
IDOC_DATA = IDOC_DATA[]
*} REPLACE
.
endif.
Please help me.
Thanks,
shashikanth.
2005 Sep 08 4:38 PM
Hi,
To resnd a failed IDOC use BD87 and specify idoc number.
If you want to send new IDOC out of a material use transaction BD10 , specify the material and receiving system.
Cheers.
2005 Sep 09 11:45 AM
Hi
You hv to put your code in user exit of BADI which will be called by FM to send IDOC.
You can try Badi BADI_MATMAS_ALE_CR or user exit
EXIT_SAPLMV01_002 ( ZXMGVU03 ) . If you give more deatils on your ALE outbound setup that will help.
Also from which FM are you pasting the code in the message.
Cheers
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |