Change date format for

Advanced Renamer forum
#1 : 31/12-23 00:27
Julia
Julia
Posts: 1
Hi - I am hoping someone can help me to change the date format when using <ExifTool:CreateDate> for my movie files.

<ExifTool:CreateDate> gives the following date format: yyyy_mm_dd hh_mm_ss (e.g., 2023_09_21 17_06_53).

I instead want the date to have the format: mmm dd yyyy (e.g., Sep 21 2023) with no timestamp.

Is there a way to do this?

Thank you all so much for your help!




31/12-23 00:27
#2 : 28/02-24 10:20
Delta Foxtrot
Delta Foxtrot
Posts: 118
Reply to #1:

Hey Julia,

Sorry for the late reply. I just recently got re-interested in this forum and came across your inquiry. You've probably figured this out for yourself by now, but here's a synopsis of ONE way to do it.

Didn't know where in your filename you wanted the Creation date; at the start may be simplest but anywhere will do. I chose the end of the filename. Here's the drill:

ADD Method: Add the ExifTool date at index 0 with "backwards" checked. I put an underscore in front of the tag to mark its beginning; best if you use something not already in the filenames.

Replace method: (to get the basic date in number form)
Replace: _(\d{4}).(\d{2}).(\d{2}).{15}
Replace with: _\2 \3 \1
Use regular expressions
Note the underscore in position 1. Replace with whatever you used (if different)

Now you create what is basically an array of month-number date-short-name pairs:
List replace:
Text to be replaced: Replace with:
_01 Jan
_02 Feb
_03 Mar
... etc. Replace underscore if...bla bla bla. THIS is where the underscore might not be the best choice if you have other "_nn" occurrences in your filenames.

That's it, although you can clean it up from there depending on your level of OCS (mine is high, I replaced the underscore with a space, etc.)

Hope that helps (if you actually see it). Holla if you need information.

Best,
DF


28/02-24 10:20