We have some customers that sends us files that are like filename.txt.txt. We even had one that had 3 .txt on it. The iussue is sometimes when we get that ands load it it escapes our duplicate file check and gets processed with the same records it had before. Is what we are looking at is potentially dropping all TXT's on a file and then slapping just one .txt on it. We cannot do this by looking for the he4 first dot because some file names have dots in it I.E. file.name.txt. We cannot use name without extention because it will drop only the last .txt which will not work if the file has 3 .txt's on it. There are 2 potential possibilities that I can think of.
1. if there is more than 1 .txt cut it down to 1 .txt
2. Drop all .txt's and then just slap one on it.
Any suggestions on the easiest way to do this.