JDBC to Multiple IDOC scenario
Dear Experts,
My Scenario is JDBC to Multiple IDOC scenario.
I am reading 100 records and generating 100 IDOC's at the target ECC system, the problem which I am facing is if I have any issue with 1 record the total message gets failed in SXMB_MONI due to mapping failure.
So again I need to reset all 100 records in my source database and I should reprocess the same.
Is there any way to process the 99 and fail only one record which causes error.
Is Stored procedure will fix this issue or do I need to use BPM for this to achieve.
Please advice.
Thanks,
--Sai
Hi Sai,
As you are selecting 100 records in one go, all the records will come as a single message in PI.
Please find below my suggestion for this issue.
1. Selecting one record per message will not be efficient. So please do not use it.
2. Create a secondary sctucture. Generate it only if there is an error in the record. You may set up an alert for that message. So if any error occurs, other 99 idocs can go normally, while you will get an aleart for the failed record.
3. Another option is to create an idoc for error record also. You can do this by providing some default values in place of error fields. You can then monitor such idocs in ECC.
Personally, i feel 2nd option is the best. Let me know if you need more information on this.
Regards,
Gavaksh
Similar Messages
-
Idoc state 56. jdbc to multiple idoc.
hi,
i have made a jdbc to multiple idoc scenario.
i disabled so many mandatory field.
i defined a external defination for the idoc.
i changed occurance for "IDOC" segment.
i can send multiple idoc successfully to ECC.
BUT:
I found that state 56 of the idoc with tcode we05 IN ECC.
how should i resolve the issue?Hi ,
In WE02 or WE05 you can find the details
status 56 is Idoc with errors added , so check you scenario
Hi,
Just take the payload from the moni and check your mapping first ( TEST TAB)
Regards,
Jude
Edited by: jude bright on Oct 21, 2009 10:49 AM -
File to Multiple Idocs scenario. Pls help
Hi All,
For Single File to Multiple Idocs scenario i am referring blog --
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/877c0d53-0801-0010-3bb0-e38d5ecd352c
Suppose my source file is
AAA, BBB,CCC
111,222,333
ZZZ,ZZZ,ZZZ
I want to make 2 IDOCS for the first 2 records (AAA, BBB,CCC and 111,222,333)
and do not want to make IDOC for the 3rd record -- how to achive this.
RegardsHi,
If the condition is like, for 'AAA' and '111', IDocs to be generated, then do as follows.
If IDOCs are of same type.
1. Value
> Equals -
> createIf -
> IDOC
Constant('AAA')
2. Value
> Equals -
> createIf -
> IDOC
Constant('111')
3. Value
> Equals -
> not -
> createIf -
> IDOC
Constant('ZZZ')
If 2 IDocs are of differnet types,
create different mapping programs with same logic.
If 2 IDocs are to be generated based on the record no in the file rather than the first field value, i think you can go for Global container.
Refer these,
[http://help.sap.com/saphelp_nw04/helpdata/en/ee/bf9640dc522f28e10000000a1550b0/frameset.htm]
[http://help.sap.com/saphelp_nw04/helpdata/EN/49/1ebc6111ea2f45a9946c702b685299/content.htm ]
[http://help.sap.com/saphelp_erp2004/helpdata/en/75/8e0f8f3b0c2e4ea5f8d8f9faa9461a/frameset.htm]
thanks.
Edited by: P.Ravi Varma on Apr 22, 2009 10:27 AM -
File-XI-multiple IDoc Scenario
Hi there -
I am working on single File-XI-multiple IDoc Scenario and have following questions:
(please keep in mind that there is already an existing multiple IDocs-XI-single File scenario between the same systems)
1. Please provide any detailed step by step documentation from end-to-end.
2. I am thinking it's compulsory to use BPM, is there any way to aviod?
3. Is it possible to update existing IDocs in R/3 directly from the data from XI?
Thanks everyone in advance...
PatHI,
Pls go thru following links-
/people/michal.krawczyk2/blog/2005/12/04/xi-idoc-bundling--the-trick-with-the-occurance-change
Single inbound file -> XI -> Multiple IDOCs in SAP
One file for multiple IDOCs
Hope this helps..
Regards,
Moorthy -
Multiple IDOC to Multiple IDOC scenario without BPM steps????
Hi
Could you please give me the solution for this ???
I want steps for sending all IDOCs at a time- ---"Multiple IDOC to Multiple IDOC scenario without using BPM".???
thanks
3nadhHello,
Refer the below, for certain details!
/people/swaroopa.vishwanath/blog/2007/01/22/ale-configuration-for-pushing-idocs-from-sap-to-xi ALE configuration for pushing idocs from SAP to XI
/people/michal.krawczyk2/blog/2005/12/04/xi-idoc-bundling--the-trick-with-the-occurance-change XI: IDOC bundling - the "trick" with the occurance change
Regards,
Jilan -
Error Handling in File to Multiple IDOC Scenario?
Hello Experts,
My scenario is file with Multiple records and I want to send it to SAP system.If there will be 10 Records in my file I need to create 10 IDOC in Target system.
I can use below of the two options.
1) File to Multiple Idoc (1.N Mapping)
2) Using BPM
3)Directly place the file in SAP application server and process it via ABAP Program.
However I am not clear in which option error handling will be more effective.Please suggest.
Basically I want to handle If out of 10 records 9 are correct and 1 record is not correct then I should be able to report within PI without affecting 9 correct records.Is it possible 9 records will be sent to SAP system and PI will only show error for 1 incorrect record.
Also I will be doing this scenrio for transaction data with huge size (1 Million Records).Which approach will be more effective in this case.
Thanks,
PushkarHi Patel,
I want to handle If out of 10 records 9 are correct and 1 record is not correct then I should be able to report within PI without affecting 9 correct records.Is it possible 9 records will be sent to SAP system and PI will only show error for 1 incorrect record.
when working on graphical mapping, the target structure is created when there are no errors in all records of source structure.
suppose if we have validation error in 9th and 10th record, then we can not process the first eight records and inturn we can not store the two error records in XI for further.
i suggest you the third option, you can directly place the file in SAP application server and process it via ABAP Program.
this is far better because you can do more customizations as you have to deal with millions of records.
Regards,
Pradeep A. -
File to multiple idoc scenarios depending on finput field value
Hi,
i have a file to idoc scenario.
depending on a particular field of the file i have to trigger a single idoc (with all the records in the file)or multiple idocs (for each record in the file ).
for example,
the file has 5 records-
2 records have field value A (create 1 idoc for all As)
3 records have field value B (create 1 idoc for each B)
so in this case 4 idocs (1 for all A, and 3x1 for B) are created
What is the best solution ?-
1. to have several outbound idoc interfaces and check each interface mapping for field value (A or B) ?
this solution seems like overwork to me
2. handle this in mapping ?
in that case will UDF be better or ABAP mapping
3. any other way ?
Thanks in advanceHi,
if you have one IDOC type you can use ABAP mapping
this way you will handle everything in tables
and you will be able to post one IDOC (bundled)
with all IDOCs inside
also if you use ABAP mapping you will be able to incorporate changes
easily in the future I believe
for idoc bundling:
<a href="/people/michal.krawczyk2/blog/2006/10/11/xi-new-book-mastering-idoc-business-scenarios-with-sap-xi"><b>Mastering IDoc Business Scenarios with SAP XI</b></a>
Regards,
michal
<a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a> -
File- XI- Multiple IDOCs scenario
Hi,
I am working on File->XI->IDOC scenario. I have a single source file and I need to map it to two IDOCs and post them to ECC. The order of posting is not an issue since it is taken care of by ECC.
I need help (detailed) on achieving this in the best possible way (using/without using BPM).
Thanks,
Guru
PS: I went through the following blog:
/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
But as per this blog, multi mapping is not possible with IDOC as the IDoc adapter is outside the Adapter Engine.As Jaishankar suggested,
going for separate mapping is a better n simple options.
Source Message Interface Mapping 1> IDOC1
Source Message Interface Mapping 2> IDOC2
Since you are sending the IDocs to the same system,
One rcvr in rcvr determination, without any condition.
in interface determinations, you have 2 inbound interfaces, and corresponding Interface mappings.
Its a simple n straighforward approach.
Regards
Pushkar Anand -
File to Multiple Idoc scenario using FCC
Hi All,
I am working in a file to idoc scenario. Here input is a fixed length file having Header and Item details which will repeat for many times.The number idoc in the target is based on the number of header in the input field. I have created a source structure with header as 1..unbounded and i have map the header with the target idoc.
In configuration part
Recordset Structure Header,9999,Item,9999
I am facing an error in communication channel as
"Conversion of file content to XML failed at position 0: java.lang.Exception: ERROR consistency check in recordset structure validation in last recordset"
Please help me to resolve this issue. Thanks in advance.Hi,
Source structure is
DATA 1...1
Record 0...unbounded
Header 0...unbounded
Item 0...unbounded
Here i am mapping Header to the target Idoc
In configuration
RecordSet Name: Record
RecordSet Structure:Header,9999,Item,9999
RecordSet Sequence:Varaible
Key Filed name : RecordType
Header.fieldFixedLength -
Header.fieldNames -
Item.fieldFixedLength -
Item.fieldNames -
Header.keyFieldValue : H
Item.KeyFieldValue :I
Header.lastFieldOptional YES
Item.lastFieldOptional YES -
File to multiple IDOCs scenario with the same receiver system
Hi guys,
I have to design and implement the following scenario:
I will receive one file with many lines (Records) with data for materials, quantities, operations etc..
Based on the values of some fields of each line, I will have to create an IDOC for each material.
For example:
if operation type = "INSERT", and Labor = 001 then create 3 Idocs of type MBGMCR with movement types=101, 261,311 that have to be posted one after the other to the same receiver system.
else if operation type = "INSERT", and Labor <> 001 then create an Idoc MBGMCR with movement type=311 and plant = 1001.
else if operation type = "Delete", and Labor = 001 the created 3 Idocs MBGMCR with movement type=312, 262 1002 and post them serially to the same receiver system.
else if operation type = "Delete", and Labor <> 001 the created 1 Idoc MBGMCR with movement type=312.
All IDOCS are posted to the same SAP R/3 system. We do not care about the sequence, except for the cases where 3 IDOCS are created.
I am trying to think of a good design in performance terms.
It is obvious that I will need BPM for sure.
I am thinking of creating a mapping program that will produce 4 message types for the different cases from the initial file and then create a different message mapping for each case from the message type to the IDOC.
I am asking you if I have to include everything (mappings) in BPM with a "fork" step?
Or shall I produce only the 4 message types and then post them to R/3 and execute the mappings in R/3?
Best Regards
Evaggeloshi,
>>I am thinking of creating a mapping program that will produce 4 message types for the different cases from the initial file and then create a different message mapping for each case from the message type to the IDOC.
To me this seems to be the right solution.
here u will create different message mappings and write them sequentially in interface determination. the multi mapping will then be utilised in transformation step in BPM.
thus if this is the only requirement there is no need of using a fork step.
[reward if helpful]
regards,
latika. -
Mapping File to Multiple IDoc Scenario
I know how to do this, but when I load the IDoc's XML structure back into the IR, the EDI_DC40 field doesn't have anything in it's structure. I need to configure the sender parameters in this structure for this IDoc, so any help would be appreciated.
Schroeder,
If I understand your question correctly after you import the IDOC into IR you want the EDI_DC40 segment filled automatically.
Either you have to fill manually or if you automatically to be filled up then check this weblog:
/people/michal.krawczyk2/blog/2005/09/01/xi-idoc-adapter--edidc40--demystified
/people/sravya.talanki2/blog/2005/12/02/manipulating-idoc-control-records-from-payload
Regards,
---Satish -
File to Multiple Idocs, Error: Tag MESSAGE1 found instead of tag IDOC BEGIN
Hi,
I have configured my file to multiple idocs scenario using the following blog -
/people/claus.wallacher/blog/2006/06/29/message-splitting-using-the-graphical-mapping-tool
Now when i try to execute this scenario it is scenario it is giving me the following error at "Call Adapter" Stage in runtime-
"Tag MESSAGE1 found instead of tag IDOC BEGIN="
My message looks like this at "Request Message Mapping" Stage in runtime -
<?xml version="1.0" encoding="UTF-8" ?>
- <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
- <ns0:Message1>
- <ZDR009>
- <IDOC BEGIN="1">
- <Z100901 SEGMENT="1">
<RUNDATE>20080220</RUNDATE>
<RUNTIME>0037</RUNTIME>
<CONSTANT1>PYRLINCST</CONSTANT1>
<CONSTANT2>CSC</CONSTANT2>
- <Z100902 SEGMENT="1">
<RECTYP>2</RECTYP>
<SSN>641381239</SSN>
Kindly assist me in solving this error, Thanks in Advance!!
Regards.
SudheerHi Sudheer,
Just the check the message mapping. Check the parant node mappings to create two different messages.
It seems that the mapping done on IDOC Node to create the IDOCs is getting failed.
Copy the content from inbound payload and test it in message mapping.
Remember, when you load the test data into your test tab you will get the error of structure mismatch coz in your mapping you have additional message.
Do the change with original data as shown below befor testing.
<?xml version="1.0" encoding="UTF-8" ?>
<ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
<ns0:Message1>
Original message will be here.
</ns0:Message1>
</ns0:Messages>
Regards,
Sarvesh -
File to multiple idoc, Raising alerts , not using ccBPM
Hi experts,
I have file to multiple idoc scenario.sturcture of the incoming file like given below..
Header
line item
line item
header
line item
line item
there is a field Company COde in Header.If that company code is not Equal to "L" then dont map that header and line items with target
now we have to raise an alert notification mail saying that "company code is wrong." we have to send a single mail for this scenario if this condition is true even many times.
i am not using ccBPM in the scenario.
how can we achieve this functionality??
Thanks in advance.
Thanks,
RohitRefer this blog to bundle multiple idocs.
/people/michal.krawczyk2/blog/2005/12/04/xi-idoc-bundling--the-trick-with-the-occurance-change
After you create the custom idoc interface using the above blog,
map the root node of the idoc interface based on your condition.
put a if condition to pass a constant to the root node for the idoc.
as an else condition, raise an exception using a udf.
Create a generic alert for runtime errors in mapping, which send mails whenever there is a failure in the mapping.
http://help.sap.com/saphelp_erp2004/helpdata/en/80/942f3ffed33d67e10000000a114084/content.htm
Regards,
Ravi -
I am working on single XML file input to multiple IDoc scenario. Single file contains multiple set of data for Customer and Vendor for example 20 Customer and 40 vendor together in one file between <CMData>...</CMdata> tag individually. I have to map Customer and Vendor based on one of the tag value. I seen the IDoc structure does not allow multiple records and occurrence shows only one. What is the best way to establish this scenario. I know ccBPM is required and Transformation Step picks respective mapping based on XML tag value for Customer or Vendor, but I have doubt how can I send one by one IDoc by identifying correct mapping based on XML tag. Thanks and appreciate your help.
--PKTThanks Paul for prompt response and support.
I changed the Occurrence of both IDOC TAG to "9999" through "xsd" and upload the same in XI and I created two mapping one for Customer and one for Vendor i.e.
File--->Customer with multiple IDoc tag attribute
File--->Vendor with multiple IDoc tag attribute
Now in BPM I have to apply loop and look to the tag XMLType and where it is "C" I have to call Customer mapping and where it is "V" I have to call Vendor mapping. How I can do this . Please help me on this. Thanks. -
JDBC to IDOC Scenario - select data in jdbc based on multiple conditions
Hello
I have a JDBC to IDOC Scenario. I have to select the records in JDBC based on different conditions each time. For example I have to select based on company code '1000' and Employee claasification 'E1' and date range. After I post these records in SAP again I want to select other records for some other company code '2000' and different business area and different dates. Basically I want to extract data multiple times based on different conditions.
Hiow do I achieve this?
Another question is in the JDBC to IDOC scenario since the sender adapter is JDBC and the sender adapter polls depending on the duration of time ( say 60 secs ) in the adapter once after I extract the data based on a condition how do I control in such a way that the same data is not extracted again.
Thanks
NagaHi Naga,
I have to select the records in JDBC based on different conditions each time. For example I have to select based on company code '1000' and Employee claasification 'E1' and date range. After I post these records in SAP again I want to select other records for some other company code '2000' and different business area and different dates. Basically I want to extract data multiple times based on different conditions.
-->
Such requirements cant be handle through select query of the sender...but you can handle this in the message mapping area.....you can fire a select query in the database to pick up records in a batch of 10K (do not keep any condition on this except for sorting). After the records come into PI you can send the message to your target based on the unique combination of "Company code+ Employee clasification + date range" handling this in the message mapping.
Another question is in the JDBC to IDOC scenario since the sender adapter is JDBC and the sender adapter polls depending on the duration of time ( say 60 secs ) in the adapter once after I extract the data based on a condition how do I control in such a way that the same data is not extracted again.
You can use the N--> C logic
The data records that you pick have a corresponding control table i assume. There should be a field STATUS where the initial status of record should be N.
After you pick the records this status should be made C so that only those records present in the database with status = N are picked up.
Mention the condition Status = N in the select query.
Thanks
Dhwani
Maybe you are looking for
-
I have the first generation ipod touch with the ios 3.01. I cannot find a way to update the software because I can no longer download apps or really do anything with it. Please help.
-
I have looked to change it from 64 bit to 32 bit, but cannot.
-
Ribbons in all programs in Microsoft Office 2013 Display different in the two user accounts
Purchased a Lenovo u530 and installed Office 2013 Home and Offce There are two accounts and all the office programs when opened in one account the ribbon section display very large in one account and small in the other. The large ribbon in the prog
-
Hi, Can you please help me to understand how Does CC&b will be interfaced with DOC1 (external billprint provider)? where can i get the technical help for the same? Regards, Priya
-
Transform keeps changing in paintComponent
I have JComponent - in my paintComponent code I want to calculate the bounds of some of the objects I'm painting so I do the following AffineTransform currentTransform = g2.getTransform(); Point p1 = new Point(clipX, clipY); currentTransform.transfor