ExifTool Forum

ExifTool => Newbies => Topic started by: Alyssa on December 02, 2014, 10:01:41 AM

Title: Adjust file create date from filename not working?
Post by: Alyssa on December 02, 2014, 10:01:41 AM
Hello
I've read the FAQ#05 about adjusting the file create date based on its filename.
I've recently recovered some screenshots from a backup whose name is in this format:
TERA_ScreenShot_20141104_201050

Its the typical YYYYMMDD_HHMMSS format, so I tried to use the command shown in the FAQ#5:
-overwrite_original "-alldates<filename" <Directory>

The images were scanned but the dates were unchanged, I thought I didn't need to specify the date format since the same FAQ states:

"This will work for any file name which matches the above criteria (eg. "IMG_20110927_103000.jpg""
(Which is the same format as my screenshot files use)
So I wonder why its not working?
Thanks
Title: Re: Adjust file create date from filename not working?
Post by: Phil Harvey on December 02, 2014, 10:14:47 AM
Try doing this on a single file and adding the -v2 option to provide more details, and post the result here.

- Phil
Title: Re: Adjust file create date from filename not working?
Post by: Alyssa on December 02, 2014, 10:20:46 AM
(https://lh6.googleusercontent.com/-6SfKfoLfOtM/VH3Yph47q4I/AAAAAAACVqg/s6Ow7eF-vjk/w579-h692-no/Senza%2Btitolo%2B-%2B2.jpg)

*Update*

Apparently if I use the tag "file:filecreatedate instead" of the "alldates" one it works.

Title: Re: Adjust file create date from filename not working?
Post by: Phil Harvey on December 02, 2014, 08:52:17 PM
Your command worked perfectly to set the common metadata date/time tags.  But you wanted to set the filesystem date/time.  You can of course set whatever date/time tags you want... you just need to figure out which ones.  This is faq 3.

- Phil
Title: Re: Adjust file create date from filename not working?
Post by: Alyssa on December 02, 2014, 08:59:18 PM
Oh okay, I thought the"alldates" included the file create date and such.

Well never mind anyway just needed the create date adjusted.
Title: Re: Adjust file create date from filename not working?
Post by: Phil Harvey on December 02, 2014, 09:57:32 PM
Yes.  The name "AllDates" is definitely misleading.  This is a Composite tag which represents only the common EXIF date/time tags.  If you really want all date/time tags, then you can use "Time:All", but I think that this would give you more than you bargained for.  (The only reasonable way to go this route would be to add -wm w to prevent ExifTool from creating new tags, but this is a somewhat advanced feature.)

- Phil