Retrieve FTP Files Using Regular Expression in webMethods/SoftwareAG

In the built-in FTP folder of webMethods, there exist one function of ftp:ls. We can put file pattern in there, but we cannot use regular expression at this step.

We can use LOOP to get dirlist, and then BRANCH, and then use Regex to check if file name fits certain pattern.

(在webMethods里面的FTP,有个功能是ftp:ls,可以输入file pattern,但是在这步还不能用Regex。可以LOOP拿个dirlist,然后再BRANCH,再用Regex测试file name是否符合什么pattern)

Here are some examples. (几个常用的如下)

In my case, I need to exclude the string that contains “success”. (在我这个例子里面,需要排除含有success的字符)

If the input is test.xml, the first step will be executed, and the second one will be ignored. (如果输入test.xml,会执行第一步,忽略第二步)

Reference site:

Originally from my post.

Author: Wenchan

Eager to explore all the interesting IT fields in full stack track, data integration and data science

Leave a Reply

Your email address will not be published. Required fields are marked *