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 Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. 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

Regex Replace Function

sneha_bhiwagade1
8 - Asteroid

Hi,

 

 REGEX_REPLACE Function to extract particular pattern from end of the string.

 

File path:  C:\Users\XYZ\2018\01\
PreviousMonth: 12

PreviousYear: 2017

Using REGEX_Replace(String, pattern, replace) function want to replace "01" month and year "2018"
with previous month "12" and previous year "2017"

 

Output path should be after using Regex_REPLACE

C:\Users\XYZ\2017\12\

 

Thanks

2 REPLIES 2
jasperlch
12 - Quasar

Hi @sneha_bhiwagade1

 

A combination of Regex, DateTime and Formula tools will do the job:

Capture.PNG

sneha_bhiwagade1
8 - Asteroid

Thank you.

Labels
Top Solution Authors