Author Topic: File renaming with unique identifier  (Read 4266 times)

Offline NicRacine

  • Newcomer
  • *
  • Posts: 2
    • View Profile
File renaming with unique identifier
« on: November 09, 2015, 03:51:53 PM »
Hi guys,

Using PM5 on Windows 10.

I am new to photo Mechanic, longtime Lightroom user, and I am trying to rename my files in the Ingest process. What I want to do is rename the first part of the file and keep the camera-assigned number.

For example, if my photo is named IMG_7201, I want to rename it SOMETHING_7201.

So I tried to use variables like this : fldr_fnm4, as fldr is the name of the folder on my DS card, and I thought fnm4 was the last four digits of the frame number (as stated in the wiki)

However, PH won't let me, stating that I need to use a unique identifyer.

What am I doing wrong?

Thanks in advance.

Offline aamodio

  • Newcomer
  • *
  • Posts: 17
    • View Profile
Re: File renaming with unique identifier
« Reply #1 on: November 09, 2015, 11:36:48 PM »
Hi NicRacine,

you had to use the variable {filebasename} with substring parameters. In you example use this rename rule:

SOMETHING_{filenamebase:4,4}.

You are telling PM to use the filename without extension (filenamebase), start to count, left to right, from first letter (that is 0 position) and take 4 chars.

You can also start to count from right to left using minus symbol: SOMETHING_{filenamebase:-4}. In this case the notation requires only one parameter.

Ciao,
A.
« Last Edit: November 09, 2015, 11:50:21 PM by aamodio »

Offline NicRacine

  • Newcomer
  • *
  • Posts: 2
    • View Profile
Re: File renaming with unique identifier
« Reply #2 on: November 10, 2015, 04:01:54 AM »
It's working, thanks!

I should not have skipped straight to the parameters definition. I've seen it in the Wiki now.

« Last Edit: November 10, 2015, 04:07:04 AM by NicRacine »