Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.
Hi all,
I am passing XML file as a mail attachment with subject line wm:tn.receive manually . I want to store it in a particular folder on the machine where IS 4.6 is installed and it should be polled and picked up by IS.How do I drop it in a particular folder?Also Is there any built in service in IS 4.6 which can poll a folder every x minute and pick up files of *.xml extension?The data from picked up file will have to be extracted and inserted into target database.Further I want to use TN at Hub end.
Thanks for any help
Hello all,
Sorry for posting wrong subject line in my previous mail.It should be Polling a Folder.
Sorry again
Raj
Hi Raj,
1)use a java service to write the XML file to a particular folder.refer built in service IO folder to write files. 2)The same folder has one more sample to list files in directory… 3) use a loop to the list and load the xml document one by one convert to records and insert to DB. 4)schedule this service (3) for the required polling time so that it lists the files in particular folder.
Hope this help you to start with.
Hi Prabhu,
Sorry for long delay in responding. What is the built in service to drop XML file to a any folder and list files in a folder? I am not able to find it. One more thought for this.Can it be done using scheduled java code which keeps polling a particular folder for specified file types? Which one is better option?
thanks again raj
You can find the services that Prabhu says in WmSaples package:
sample.IO.utils:listFilesInDirectory
greetings,
Sebastian
Hi raj,
sample.IO.utils:listFilesInDirectory ,as sebastian pointed its in that folder.I suggest the polling option would be much easier.
Thanks and Regards, Prabhu.