cancel
Showing results for 
Search instead for 
Did you mean: 

need help in udf logic

Former Member
0 Kudos

Hi XI / java Experts

every day we are getting some idoc xmls which included the idoc number in the payload. at the end of all individual idoc xmls a final idoc xml triggers which includes all the above Idoc numbers that are processed indivuadally. This is the routine process.

but, sometimes in this final Idoc xml there some additional idoc numbers were included, those were not processed individually.

My requirement is to send a mail to the sender telling that, In the final Idoc xml some additional idoc numbers are included for those additional idoc xml, individually are not received at my end.

for this i need to prepare a file to list all the idoc numbers which were received at my end and once the final idoc comes it should compare with the file which contains the individual idoc numbers in the file. if any mismatching in the number of idocs in the file, a error file should be generate telling that mismatch of idoc numbers.

Pls tell me how to write UDF(code) to achieve this requirement.

Thanks

Robin

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hello,

What U can do is u can store the IDOC number while they are transmitting individually in file system in a file and while last file was going u can compare the idoc number......if u not find the idoc number u can store in a global conatiner once comparison completes u can send the file though mail adapter.

For this u can use UDF.

In udf u can open a ftp connection where the file is present for the individual processed idoc and then comapare it with the last file.

/people/william.li/blog/2006/04/18/dynamic-configuration-of-some-communication-channel-parameters-using-message-mapping

refer -

/people/jayakrishnan.nair/blog/2005/06/20/dynamic-file-name-using-xi-30-sp12-part--i

/people/jayakrishnan.nair/blog/2005/06/28/dynamic-file-namexslt-mapping-with-java-enhancement-using-xi-30-sp12-part-ii

Thanks and regards

Hemant

rajasekhar_reddy14
Active Contributor
0 Kudos

> but, sometimes in this final Idoc xml there some additional idoc numbers were included, those were not processed individually.

>

is there any condition to identify the additional IDoc numbers??

> My requirement is to send a mail to the sender telling that, In the final Idoc xml some additional idoc numbers are included for those additional idoc xml, individually are not received at my end.

>

use mail adapter to send mail to corresponding person,befor that you have to identify the additonal IDoc numbers.

> for this i need to prepare a file to list all the idoc numbers which were received at my end and once the final idoc comes it should compare with the file which contains the individual idoc numbers in the file. if any mismatching in the number of idocs in the file, a error file should be generate telling that mismatch of idoc numbers.

>

i am not sure about UDF,if you provide the sampla file kind of that we will give you an advice UDF /JAVA mapping.

if any file look kind of stuff required to validate/find aditional stuff better to go with simple JAVA map.

Regards,

Raj