In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Extract "Strings" from a list of files names

Terrymax
7 - Meteor

Hi All

 

I have a list of files names, i want to extract strings in the 1st () and the last () of each file names below , then write to a new filed.  

 

The expected format like  : zz aaa ; zz bbb

 

List Name

MASTER (ZZ) DAT FILE v16(Final)_xxxx (aaa)_Jun'21.xlsx
MASTER (ZZ) DAT FILE v16_xxxx (bbb)_June'21.xlsx
MASTER (ZZ) DAT FILE v16 (2021) (cccc)_Jun'21.xlsx
MASTER (ZZ) DAT FILE v16 (2021) (dddddd)_Jun'21.xlsx
MASTER (YYY) DAT FILE v16 (2021)_xxxx (eeeeeei)_June'21.xlsx
MASTER (YYY) DAT FILE v16 (2021) _xxxx(ffffff)_June '21.xlsx
MASTER (YYY) DAT FILE v16 (2021) _xxxx(gggggg)_Jun '21.xlsx
MASTER (YYY) DAT FILE v16 (2021)_xxxx (hhhhhh)_17 Jun 2021.xlsx
2 REPLIES 2
RolandSchubert
16 - Nebula
16 - Nebula

Hi @Terrymax ,

 

you can use FindString to find the first "(" and ")" and SubString to extract the string between the brackets, for the last brackets the same would be possible using ReserveString - you have to find the string between ")" and "(" and reverse the result. I've attached a sample workflow. Of course it is possible using RegEx as well.

 

Let me know if it works for you.

 

Best,

 

Roland

Terrymax
7 - Meteor

It works! Super! Thanks so much! 

Labels
Top Solution Authors