Author Topic: Increment sequence # in file name?  (Read 2608 times)

Offline theim

  • Member
  • **
  • Posts: 67
    • View Profile
Increment sequence # in file name?
« on: February 16, 2010, 11:27:13 AM »
Dear Kirk,

Is there any way to add a fixed numeric value to sequence #s already in file names?

For instance, if I currently have the following images named:
2009_1101_001_Ballgame.nef
2009_1101_004_Ballgame.nef
2009_1101_009_Ballgame.nef

Is there a way to rename them such that the new file names will have been incremented by a value of 200?
2009_1101_201_Ballgame.nef
2009_1101_204_Ballgame.nef
2009_1101_209_Ballgame.nef

My guess is that the 'numbers' 001, 004, 009, etc. are really string and not numeric, making this impossible.
Still, I was hoping there might be some kind of solution such as:
{filenamebase:0,10}{filenamebase:10,3}+10_Ballgame

Perhaps, {filenamebase:0,10}value({filenamebase:10,3}) + 200
would do it?  (of course, I made up the 'value()' function).

I'm guessing the answer is no, but thought I'd ask anyway.

As you may have guessed, I found 200 photos which were shot earlier in the same day.
I can't just rename the files sequentially, as there are 'gaps' (some shots were deleted) and I want the original numbers retained (except being incremented by 200).

Thanks and best regards,
-Tom

Offline theim

  • Member
  • **
  • Posts: 67
    • View Profile
Correction:
« Reply #1 on: February 16, 2010, 11:40:20 AM »
Make that...

{filenamebase:0,10}{filenamebase:10,3}+200_Ballgame

...in my previous example.

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 24730
    • View Profile
    • Camera Bits, Inc.
Re: Correction:
« Reply #2 on: February 16, 2010, 01:05:11 PM »
Tom,

Make that...

{filenamebase:0,10}{filenamebase:10,3}+200_Ballgame

...in my previous example.

No, there is currently no way to do that sort of thing directly.  You could process them in batches like so:

2009_1101_2{filenamebase:12,2}_Ballgame

... for the first group of 100, and then process any other groups, changing the '2' to a '3' and so forth.

-Kirk

Offline theim

  • Member
  • **
  • Posts: 67
    • View Profile
Re: Increment sequence # in file name?
« Reply #3 on: February 17, 2010, 08:16:13 AM »
Dear Kirk,

No problem - that makes sense.

And thank you for such a prompt response, which allowed me to move forward right away.
I purchased a relatively inexpensive 3rd-party renaming utility for Mac ($20) which did just what I needed.

I don't expect Photomechanic to do everything, in fact I prefer it the way it is.
PM is a lightening-quick tool for all my front-end work (renaming, culling, metadata tagging, previewing, searching, etc.).

The renaming capabilities in PM serve all my needs for 99% of the time.  This happened to be a rather unique situation.

Thanks again for such a valuable application.  I don't know what I'd do without it!

-Tom