Mapping in idoc segment
Hi
I am using ARTMAS04 idoc from sender side in which i have segments and following fields
E1BPE1MATHEAD(Segment max occurence is 1)
MATERIAL
E1BPE1MARMRT(Segment max occurence is 999999)
MATERIAL
EAN_UPC
Even my target side also is ARTMAS05
My condition for mapping is i need to compare material in E1BPE1MATHEAD segment with material in
E1BPE1MARMRT if both are same then i should not pass EAN_UPC field to other side, if materials are different then only i should pass the field EAN_UPC to target side.
What is the logic should i right to meet the above condition.
I tried by using equals and if logic,but it is not working.
regards
raghu
Hi Raghu
Try with this
IfWithoutElse(Not(E1BPE1MATHEAD/MATERIAL equalS E1BPE1MARMRT/MATERIAL)) then EAB_UPC -> Target
Thanks
Gaurav
Similar Messages
-
Mapping: Each IDoc Segment to single new IDoc
Hi, can someone provide me with infos on how to solve this problem?!
Do i have to use BPM and when, is there any tutorial on this?!
We have two different Segments in IDoc and for each occurance they should be collected in two different IDocs, so that each contains one type of segment.
Can u please help?!
brHi Fritz,
You can use collect pattern when there is requirement of collecting multiple messages .For example i have an applicaion where i can send purchase order from different vendors.Now i wish that at the end of day i get one consolidated purchase order for each vendor instaed of multiple orders from a particular vendor then i can utilise it.Correlation will be required as the messages have to be grouped based upon a particular Information like in our example its vendor
Collection of IDoc to Single File
IDOCs (Multiple Types) Collection in BPM
Collecting IDocs without using BPM By Stefan grube's
Collecting IDocs without using BPM
BPM CollectPattern..
http://help.sap.com/saphelp_nw2004s/helpdata/en/08/16163ff8519a06e10000000a114084/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/de/766840bf0cbf49e10000000a1550b0/content.htm
http://help.sap.com/saphelp_nw04/helpdata/en/cb/15163ff8519a06e10000000a114084/content.htm
http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/content.htm
Illustration of Multi-Mapping and Message Split using BPM in SAP Exchange Infrastructure
Posting multiple IDocs with Acknowledgement
Also have a look at these seminars,
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/media/uuid/daea5871-0701-0010-12aa-c3a0c6d54e02
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/media/uuid/e8515171-0701-0010-be98-e37bec4706cc
IDOCs (Multiple Types) Collection in BPM - Collection of IDoc to Single File
Using a BPM to collect messages for a set interval of time
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/30ea2fdf-f047-2a10-d3a2-955a634bde6b
Also this link,
http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/content.htm
Regards,
Vinod. -
Inbound Invoice idoc segment feilds mapping to SAP feilds
Hi,
Could you please help me to find out the tables and feilds in SAP for the inbound invoice idoc type INVOIC01. I need to map the idoc segment fields with SAP fields and respective tables.
Thanks in Advance
SatishHi Satish,
That's quite a big case to get such mapping - why would you need it really? You can process Idoc with std process codes and you will see the std mapping then happening.
You can also go through logic of processing modules:
Function Module Name Short text for function module
IDOC_INPUT_INVOIC_FI EDI: Invoice Receipt (INVOICE)
IDOC_INPUT_INVOIC_MM EDI: Invoice Receipt (INVOICE)
IDOC_INPUT_INVOIC_MRM
For sure you will get RBKP for header, RSEG for items, RBTX for taxes and some more, depending on what you get in the invoice and what are your booking and matching processes.
Best Regards,
Tomek -
How to map idoc segments to multiple output structures
Dear experts,
On Pi I need to map segments from an Idoc to 2 different outputstructures. My scenario is as follows:
incoming Idoc on PI -> if segment eq 'X' then map to outputstructure '1'; if segment eq 'Y' then map to outputstructure '2'
Idoc structure is as follows:
- 1 header segment
- 1..n detail segments (which I need to map to outputstructure 1)
- 1 summarisation segment (which I need to map to outputstructure 2)
Output needs to be a .txt file.
I would like to use the graphical message mapping on PI, how can I map the Idoc to multiple output structures?
Thanks in advance,
WilliamHi
You can do 1:n multimapping
in message mapping in messages tab ..add both the structures in target tab and do the mapping
and in operation mapping add both the message interface on the target side
PLease go through this blog
/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible -
Idoc error mapping error for segment "E1EDT13 006" in DESADV idoc
Hi SAP Gurus,
DESADV IDOC for few articles is not getting passed from SAP to legacy system. It is missing one segment"E1EDT13 006" for goods issue.
Why is this mapping error happening. How can this be resolved.
Regards.
SumiHi Nsangle/SAP gurus,
Thanks for that. But, I have already compared the failing idoc with the successful one. It's the segment E1EDT13 006 missing in the wrong idoc. I have already added that idoc and reprocessed it.
But, I wanted to know why such kind of idoc segment missing/ mapping error happens.
Regards.
Sumi -
How to map idoc segment field E1IDB02-FIIKONTO with BSEG-ESRNR.
Hi,
I have searched for lot of threads in the forum , and also i tried myself but i am not able to map this fields segment with my logic, so please anyone kindly contribute in mapping idoc segment field with the logic given below:
idoc type :PAYEXT outbound idoc.
message type: PEXR2002
This is my logic: i need to populate the ISR number(BSEG-ESRNR ) in idoc segment field( E1IDB02-FIIKONTO)
DATA : str1 TYPE string,
len1 TYPE i,
len2 TYPE i,
str2 TYPE string,
str3 TYPE string.
str1 = '01-1234-4'. ---> BSEG-ESRNR "ISR Subscriber Number
REPLACE FIRST OCCURRENCE OF '-' IN str1 WITH '_'.
REPLACE ALL OCCURRENCES OF '-' IN str1 WITH space.
CONDENSE str1.
len1 = STRLEN( str1 ).
IF len1 LT '9'.
len2 = '9' - len1.
CASE len2.
WHEN '1'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH '00'.
WHEN '2'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH '000'.
WHEN '3'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH '0000'.
WHEN '4'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH '000000'.
WHEN OTHERS.
ENDCASE.
ELSEIF len1 EQ '9'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH '0'.
ELSEIF len1 GT '9'.
REPLACE ALL OCCURRENCES OF '_' IN str1 WITH space.
CONDENSE str1.
ENDIF.
Thanks in Advance.Resolved.
-
Hi,
How can i change the field attached to a IDOC segment.
Actually we have this Invoice IDOC,in which the E1EDK03 012(Qualifier) is passing the IDOC creation date instead of Billing date.
So i need to change this mapping to Billing date.
Please help.Hi Salz,
I just checked my version of SAP (4.7) and you should get an invoice date. Check out the subroutine FILL_E1EDK03 in function module IDOC_OUTPUT_INVOIC. The first section of this code creates an E1EDK03 segment with the invoice date (if there is an invoice date), with qualifyer 026.
Is there a possibility that in fact you are getting an E1EDK03 segment with the invoice date, but you are also getting other E1EDK03 segments (such as the one you mention with qualifyer 012) and they are obscuring the one you are looking for?
If there are definitely none being created then can I suggest that you debug the subroutine FILL_E1EDK03 in function module IDOC_OUTPUT_INVOIC to check what is happening. You may need to change the timing of your output record to 1 and run the program RSNAST00 online to get the breakpoint to be hit correctly.
If, in your version, the code doesn't include this date, then you have an exit function module EXIT_SAPLVEDF_002 (called via the subroutine CUSTOMER_FUNCTION in function module IDOC_OUTPUT_INVOIC) where you can actually add your own segment data. For example you an change the contents of an existing segment (as per your original request), or append your own E1EDK03 segment with your own data. I would recommend adding your own segment rather than changing whats there.
It is possible to extend idocs to add your own custom segments (eg Z1EDK03), but I wouldn't recommend it in your case, because in later versions of SAP the date is provided and by not creating a new segment (Z1EDK03) you will have no mapping changes to do when you upgrade. You can just delete your userexit code.
Hope that all makes sense and helps you with your problem.
Cheers,
Brad -
XI Mapping to Idoc - Multiple Identical Idoc Segments
I am debuuging XI mapping. I see the same idoc segments in the mapping multiple times. However, the way the fields are mapped in each one is different.
Why? Is this to handle different scenarios?
Thanks.in IDOCs each segment could occur multiple times. Lets say if its a address segment, u could see it multiple times for billing, shipping etc etc. so, depending on business logic the mapping will change. Some fields you'll map to one segment and some fields to some other segment.
--Archana -
I facing one situtation in mapping Custmosied IDOC a new segment is add t
HI Gurus
I facing one situtation in mapping Custmosied IDOC a new segment is add to that IDOC.... i want to display values in queues in mapping test.. but queue is empty it showing ,,,
already i have checked IDX2 .. in that it is updated about the segement .. let me know solutiuon y it is not populate in that segemnt ..\
thanks in advance.Hi ,
Have you imported the IDOC into ESR after the changes were done in the ECC side?
Is the mapping done for the new segment/fields properly?
Please check what values are passed in the segment from ECC?Try triggering a message from WE19 with test values and check if you are receiving the same?
Please explain little more on this...
Regards,
Srinivas -
Mapping Items in XML string to multiple IDOC segments
I would like to map an XML tag <Text>Line1Line2Line3Line4</Text>
to an IDOC segment E1ED1TEXT . Defined as occurring 0 to 999999.
I would like to map each item separated by a tilde into a separate occurence of the IDOC text segment. Is ther anyway to repeat the mapping without duplicating the subtree.
E1ED1TEXT
Text_Id - "ZTXT"
Text_Line = Line1
E1ED1TEXT
Text_Id - "ZTXT"
Text_Line = Line2
E1ED1TEXT
Text_Id - "ZTXT"
Text_Line = Line3Hello,
This is only possible using UDF
mapping is like this:
Text -> UDF -> splitByValue:eachValue -> Text_Id
UDF is of context type
argument is input
String temp[] = input[0].split("~");
for(int a=0;a<temp.length;a++){
result.addValue(temp[a]);
Hope this helps,
Mark -
Mapping problem: IDOC - XI - File
Hi,
in my scenario (Z-IDOC - XI - File) I have problems with the mapping:
Z-IDOC :
ZFIBUCH1
_IDOC
___Begin
___EDI_DC40
___Z1L061 (0..999999999)
_____Z1L062 (0..999999999)
example
L061 18000 DE 0101 23236318 050605 EUR
__L062 18000 XXX XXX
__L062 18000 XX1 CCC3
L061 87000 DE 0101 050605 EUR
__L062 87000 XXX XXX
__L062 87000 XX1 XAA4
the result should look like this :
L061 18000 DE 0101 23236318 050605 EUR
L062 18000 XXX XXX
L062 18000 XX1 CCC3
L061 87000 DE 0101 050605 EUR
L062 87000 XXX XXX
L062 87000 XX1 XAA4
I tried the following (target)-data types in the mapping but nothing didnt work very well :
MT_ZIFUCH_FILE
__ row
_____L061
_______L062
or
MT_ZIFUCH_FILE
__ row
_____L061
_____L062
or
MT_ZIFUCH_FILE
_____L061
_____L062
Do I need here a BPM? Or should I use XSLT-Mapping??
Or knows somebody a easyer way?
Regards
ChristophHi,
As per my understanding to have a flat file struture you would require a flat structure at the target side.One similar to the second structure mentioned by you.
DT_Target
|_Header
|______L61.....segment (child of header)
|______L62.....segment (child of header)
Using the mapping we convert the idoc structure to flat structure and then use content conversion like this :
Recordset structure : L61,L62
L61.fieldSeparator = ,(for you this value should be space)
L62.fieldSeparator = ,
I have not been able to convert the Target hierarchial structure to a flat file via content conversion.
when i tried I got the values as
L61,1800,...EUR,L62,8700,......
Hope this helps,
Regards,
Sulakshana -
Advanced mapping from IDOC to SOAP with reversed 3 level context change
Hi everyone.
I am having a though time mapping the HRMD_A01 IDOC into a SOAP message. The reason is that the reciever expects an xml structure where the root node is cost center instead of employee which is the case in the IDOC.
Mapping from:
IDOC (1..1)
E1PLOGI (1..unb)
SEGMENT (String)
OBJID (String)
E1PITYP (1..unb)
E1P0001 (1..unb)
SEGMENT (String)
KOSTL (String)
To this structure:
List (1..1)
CostCenters (1..unb)
KOSTL (String) ----> Mapped against KOSTL above
Employees (1..unb)
OBJID (String) ----> Mapped against OBJID above
I expect several occurances of E1PLOGI which states multiple employees sent in the IDOC. I also expect several occurences of E1P0001 containing cost centers.
My conclusion is that I need an advanced mapping and I have created one which collects all KOSTL for the IDOC context, deletes duplicates, and creates the CostCenters segment. This is now working. But my problem is that I can't create the employees segment in the right place. They are only created once under the first CostCenters node.
Here's the java-code for mapping between KOSTL and CostCenters/KOSTL:
public void costCenters(String[] var1, ResultList result, Container container) throws StreamTransformationException{
Set set = new HashSet(Arrays.asList(var1));
String[] array2 = (String[])(set.toArray(new String[set.size()]));
Arrays.sort(array2);
for (int i = 0; i < array2.length; i++) {
result.addValue(array2<i>);
Any ideas on how to proceed?
Best RegardsHi,
Do the mapping like below.
UDF should be select as context.
List (1..1)
CostCenters (1..unb)
KOSTL (String) ----> Mapped against KOSTL above
Employees (1..unb)
OBJID (String) ----> Mapped against OBJID above
Mapping:
KOSTL(RightSelectChange the context to E1PITYP)--UDF--Removecontext--CostCenters
KOSTL(RightSelectChange the context to E1PITYP)--UDF--SplitbyValue(Each Value)--KOSTL
constant---Employees
OBJID----------------------------------------------Use One As Many---SplitByValue (EachValue)----------OBJID
KOSTL(RightSelectChange the context to E1PITYP)--UDF---
KOSTL(RightSelectChange the context to E1PITYP)--UDF---
Regards,
Prakasu.M
Edited by: prakasu on May 20, 2009 3:28 PM -
Hi,
Iam new to idocs and a functional consultant. I need to know whenever we receive the inbound idocs and if i see the segments of the inbound idoc, do the fields which i see in the segments are the sap fields.????/ for instance if the inbound idoc needs to create a sales order, then the fields of the segments of such an inbound idoc are the normal sap sales order fields ??
do i need to give functional specs to the abapers that whenever the inbound idocs is received the segments fields need to be mapped to sales order fields if such an idoc needs to create a sales order ??
regards
sachinHi Sachin,
Most of the IDoc segment fields are simmilar to SAP transaction fields e.g. most of the ORDERS IDoc segment fields will be simmilar to what you can see in VA01/VA02 screen fields.
Some fields may have different names.
In the case of few segments which may repeate in IDoc with different qualifiers (such as partner details, date segments), fields will be same but different qualifier value decides where these field values will be populated in the Order.
If you are using standard function module to create Order, it will take care of mapping IDoc segment fields to VA01/VA02 screen fields. But if it is a Z function module, then you need to specify the mapping.
Hope this information will help you.
Regards,
Mahesh Pakhale -
Hi,
I want to migrate orders from our legacy system to SAP. I use IDOC SALESORDER_CREATEFROMDAT200. My Input files are order header and order items. I connect the two input files to the corresponding IDOC segements.
But how can I repeat an IDOC segment. I want to create the IDOC segment E1BPPARNR twice. One side for PARVW AG and on the other side for PARVW WE. Is it possible to repeat the IDOC segment without connecting it to an additonal file, which contains the partner data with the two records for AG and WE ?
thanks
UliIn order to repeat a segment with different data coming from the same file, follow these steps:
Go to Field mapping and conversion rules
Click on "Extras" (menu bar) > Layout and check "Processing time"
At the end of your segment, you will see a field called "__END_OF_RECORD__" having the ABAP statement "transfer_record." After that code, you need to enter the mapping for each field of your second segment (you can copy-paste code from the previous fields and simply change the source field (the one from your flat file).
Add another "transfer_record." statement after your code. -
Idoc Segment - Context Handling.
Hi All,
Can anyone suggest me a solution as how to handle the below idoc context problem.. its a file to idoc scenario
I have an Debmas idoc, in which It is possible for a customer to have more than one E1KNBKM segment, so we only want to map the first segment for that customer and then also we only want the information from the /GLB/XGT_EXTRA_17 segments that are child segments of E1KNBKM.
-AnuWhat Ravi suggested was:
SourceNode --> Index -->
--> equalS --> ifWithoutElse (Then SourceNode) --> TargetNode
Constant(1) -->
Index is similar to Count function (just that it is more reliabel when counting multiple node occurences)...the above will check if the occurence of SourceNode isthe first or not.
Regards,
Abhishek.
Maybe you are looking for
-
Can i tunes combine previous acct to new acct,if the old acct password is lost?
-
Not able to log in to OBIEE 11.1.1.5
I have installed OBIEE 11.1.1.5 on my laptop with Windows 7 and it was working fine. I did not work on it for few months and now when I am trying to login to dashboard page with weblogic as user name I am getting Invalid user name or password error.
-
Can I choose my own billing due date?!
-
Hello, I am looking to see if it is possible to access the camera within an iPad (Air) Application. I have quiz that I have already deployed to an iPad but I want to be able to take a photo at the end of the quiz and somehow send to another comptuer
-
Multiple SSL Certs in one SSL Proxy/VIP
Guys I have a requirement to be able to provide SSL for two different sites that will resolve to the same VIP. Ive created alot of SSL sites before and these work a treat with HTTP to HTTPS redirection. However Im not sure how are take two different