ExifTool Forum

General => Other Discussion => Topic started by: alihusnainc1 on February 24, 2021, 10:25:47 AM

Title: Change created date of .mp4 video clips and set according to the filenames.
Post by: alihusnainc1 on February 24, 2021, 10:25:47 AM
I have a bulk of videos that i need to import to iphotos, but before that i need to change the created_dates of files otherwise they will be sorted and considered as most recent.
Current file naming convention: clip-2008-01-13 05;46;43.mp4

Is there a way to change metadata of all .mp4 files placed in a directory?
Your help in this issue will be appreciated.
Title: Re: Change created date of .mp4 video clips and set according to the filenames.
Post by: StarGeek on February 24, 2021, 10:33:40 AM
exiftool "-CreateDate<Filename" /path/to/files/

This command creates backup files.  Add -Overwrite_Original (https://exiftool.org/exiftool_pod.html#overwrite_original) to suppress the creation of backup files.  Add -r (https://exiftool.org/exiftool_pod.html#r-.--recurse) to recurse into subdirectories.
Title: Re: Change created date of .mp4 video clips and set according to the filenames.
Post by: alihusnainc1 on March 08, 2021, 04:03:46 AM
Thanks StarGeek,
It works just fine !

The only problem is that for me clip-1998-09-17 12;17;09.mp4 comes out with 17-september-1998 8:17:09PM (rather than 12:17:09PM).
Is there any timezone issue but i set the datetime according to filenames that are static? If yes, then how can i fix it.

Regards,
Ali
Title: Re: Change created date of .mp4 video clips and set according to the filenames.
Post by: Phil Harvey on March 08, 2021, 06:54:33 AM
Hi Ali,

Try adding -api quicktimeutc to the command.  Read here (https://exiftool.org/ExifTool.html#QuickTimeUTC) for an explanation of this option.

- Phil