Hi,
Can I ask for your assistance in extracting the folder name from a directory as well as the date? The directory are as follows:
\\po-nas4.xyzcompany.net\pib_mkts_00001_prd_335$\.seb\bus\khf\SNARL\hf3\input\DB LockPAWNLevel\8029-5542364859.20240912.SBLock_Mumbo_SECD_MODELX\
a. I would like to get the folder name "8029-5542364859.20240912.SBLock_Mumbo_SECD_MODELX"
b. extract the date 20240912 and covert it to date type 2024-09-12.
Thanks and looking forward for response.
Kamen
Solved! Go to Solution.
@KamenRider this sounds like the RegEx tool would be an ideal candidate. The Advanced Certification learning path has a section all about the RegEx tool and would help you figure out the formula to use.
Hi @KamenRider
@cpet13 is right, the key functionallity for the solution here is regEx.
Attached a sample workflow with the solution as you described.
Let me know if it works for you 🙂
There are several ways how to get it done, you can do it with REGEX in formula tool or without REGEX in formula tool, or with REXGEX Parse tool or Text To Columns Parse tool.
While REGEX will work well here I think that there is a better way here to get what you want than with REGEX. With a simple formula tool you need to reverse the text flow, find the first position of the \ then use Left and use the position -1 and then reverse your text and you got the Folder name.
@KamenRider one way of doing this