cancel
Showing results for 
Search instead for 
Did you mean: 

File to Multiple IDOCs

former_member188791
Participant
0 Kudos

Hi Group,

I have a requirement to create/change/delete material master using FIle to IDOc scenario, I am receiving one source file and based on one field value I need to create MATMAS01,MATMAS02 and MATMAS05, can any body suggest what is the best way to achieve this using PI.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos
former_member188791
Participant
0 Kudos

Hi Harish/Amit,

Thank you for your response, here main issue is error handling, if any record failed I need to skip that record and go to process other one and error records needs to collect and send the refence of the record through alerts.

Former Member
0 Kudos

Hello,

>>if any record failed I need to skip that record

That's a very generic statement, record can be failed due to many reasons so that means for every field u want to do some kind of validation??

But, if u r only concerned abt the validation of mandatory fields then u can split ur interface into 2 steps:

----Pick files from source server and in ur message/java mapping do ur validations and split the successful/erroneous records. Then create one new file with validated records and dump the same on NFS location (regarding failed records read below).

---Then Second interface will be the usual one i.e. File to Idoc which will pick validated files created using interface 1

>>error records needs to collect and send the refence of the record through alerts.

Since u r only segregating the correct records with the incorrect one and not failing anything, so PI won't throw any alerts. What u can do is either send that failed records to some error folder  or send a consolidated email (with unique key present in the failed record)

>>if any IDOC Errors/Errors during Material creation/change.

In ECC, u can configure workflows to send email in case of Idoc errors... Check SDN u will certainly find articles pertained to that.

One more (easy) work around - so just thought of sharing in case u r working on PI7.31, then use XML validation feature and fail entire file in case validation gets failed + send that failed file to some error (ftp) folder + raise alerts. This would certainly makes ur job easy

An alternative of the same in PI7.1 is below:

http://scn.sap.com/community/pi-and-soa-middleware/blog/2012/01/30/xml-xsd-validation--an-alternativ...

Thanks

Amit Srivastava

former_member188791
Participant
0 Kudos

Hi Amit,

Thank you for your response, but still I am not clear how we will consolidate PI side Errors(madatory field check) and ECC side Errors in to one Error file and send in to mail attachment, can any body have suggestion

former_member188791
Participant
0 Kudos

Hi Group,

Can any body have solution to my query

Harish
Active Contributor
0 Kudos

Hi Rajiv,

you can achive these with multimapping. You can map the source file to METMAS01, MATMAS02 and MATMAS05 IDOC based on your condition.

if you file structure is deep and you have problem to convert it into XML then i would suggest to go for Java mapping otherwise this functionality can be achieve from graphical mapping.

Regards,

Harish

former_member188791
Participant
0 Kudos

Hi Harish,

Thank you for your reply, do you mean multi mapping with BPM? also I need to capture Error of that particular records, if any records fails I need to skip and needs to process another record,is it possible with Multi mapping

Harish
Active Contributor
0 Kudos

Hi Rajiv,

for the above requirement you do not need the BPM.

I need to capture Error of that particular records, if any records fails I need to skip and needs to process another record,is it possible with Multi mapping

--> it is possible, can you please provide some more details that do you want the structure validation or data validation, based on that you can trigger a flow and capture the error.

Regards,

Harish

former_member188791
Participant
0 Kudos

Harish ,

The details are below:

in PI

-----

Structure validation (Madatory/Optional fields)

in ECC

----------

if any IDOC Errors/Errors during Material creation/change.

I need to trigger alert for all the above errors to notify support team,any idea how we can achieve this

Harish
Active Contributor
0 Kudos

Hi Rajeev,

you can perform structure validation at adapter or integration engine level using the standard functionality provided by PI. you can configure this at sender agreement level.

For any error occure in PI, you can genrate the alerts and support team can be notify using that. the content of alert you need define.

For error in ECC (error with IDOC), you need to trigger the alert in ECC. I am not sure how we can genrate the alerts in ECC, but there should be a machanism to genrate alerts in case of message error.

Regards,

Harish