in windows if i use:
exiftool "-filecreatedate='%4.0f:%2.4f:%2.6f %2.9f:%2.11f:%2.13f'" -if "(not $timecreated & $filetype eq 'JPEG')" 20150817_203810.mp4
i get:
Warning: Invalid date/time (use YYYY:mm:dd HH:MM:SS[.ss][+/-HH:MM|Z]) in File:FileCreateDate (PrintConvInv)
Nothing to do.
however if i use to confirm the string i'm creating:
exiftool "-testname=%4.0f:%2.4f:%2.6f %2.9f:%2.11f:%2.13f" -if "(not $timecreated & $filetype eq 'JPEG')" 20150817_203810.mp4
'20150817_203810.mp4' --> '2015:08:17 20:38:10'
0 image files updated
1 image files unchanged
and if i use:
exiftool "-filecreatedate=2015:08:17 20:38:10" -if "(not $timecreated & $filetype eq 'JPEG')" 20150817_203810.mp4
1 image files updated
so somehow i'm not able to take the string created and use that as a tag. I'm assuming its a regular expression or tag formatting issue... Please save me?
The %d, %f, %e format codes are only valid where a file name is expected, so what you have done won't work. It works with TestName because that tag expects a file name.
But luckily your file names are formatted such that, you can do what you want even more easily:
exiftool "-filecreatedate<filename" ...
But there are other problems with your command:
1. Are you sure you want to test "TimeCreated" in your -if statement? Not "CreateDate"?
2. The "&" operator is a bitwise and. I think you want the logical "and" operator instead.
- Phil