Skip to Content
avatar image
Former Member

Help needed on Regular expression for PI SFTP Adapter

hello people,

We are using SFTP Adapter version 1.0 with PI version 7.1.

We need to pick files in the format "US_GSI_2054_VPV1490.txt" so we had given the filename scheme as US_GSI_2054_VPV*.* and it was working fine. The numbers coming after VPV keeps changing.

The issue we are facing now is there are other set of files in the same source folder with file name scheme, US_GSI_2054_VPVCHECK*.* Example: "US_GSI_2054_VPVCHECK1234.txt"

We do not want out sender channel to pick these files.

We tried giving the name scheme in channel as US_GSI_2054_VPV[0-9]*.*

But this picked the VPVCHECK files also.

Could you please help with the expression to be mentioned in the sender channel to skip the VPVCHECK files. We do not have file exclusion mask option in this adapter.

Thanks in Advance,

Sriram.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Mar 15, 2017 at 07:34 AM

    RegEx: US_GSI_2054_VPV[0-9]+.* mens there is at least one digit after the VPV and that will not be valid for

    US_GSI_2054_VPVCHECK1234.txt file

    There are a few qualifiers for RegEx, check for example here:

    https://msdn.microsoft.com/en-us/library/3206d374(v=vs.110).aspx

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 15, 2017 at 12:34 PM

    Hi Milan,

    It worked. Thanks for your quick help.

    Regards,

    Sriram

    Add comment
    10|10000 characters needed characters exceeded