MRT - How to rename part of a variable in filename?

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
Vlayke
New Member
New Member
Posts: 1
Joined: 2013-09-09, 13:32 UTC

MRT - How to rename part of a variable in filename?

Post by *Vlayke »

I have the following situation.
Filename is in format:

name.name.YYYY.DD.MM.name.name.ext

I would like to rename it to the following format:

name.name.YYYY-DD-MM.name.name.ext

My problem is that I'm unable to provide a filter that would select just the two "." characters in the YYYY.DD.MM to change them to "-" characters.

Can you provide any help?
Thanks
User avatar
white
Power Member
Power Member
Posts: 6015
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

Search for: (\d\d\d\d)\.(\d\d)\.(\d\d)
Replace with: $1-$2-$3

Regex
Post Reply