ExifTool Forum

ExifTool => Newbies => Topic started by: Smajors on January 01, 2019, 06:56:47 PM

Title: Help needed on modifying DateTimeOriginal on Canon CR2 Images
Post by: Smajors on January 01, 2019, 06:56:47 PM
I am needing to adjust the Date/Time of a number of photos (a little over 1800 of them...) by adding 1 year and 9 hours

In Terminal (Mac) I run exiftool -time:all -s /FILE
This is what I get:
FileModifyDate                  : 2017:12:28 07:14:50-07:00
FileAccessDate                  : 2019:01:01 16:06:42-07:00
FileInodeChangeDate        : 2019:01:01 14:35:43-07:00
ModifyDate                      : 2017:12:28 07:14:46
DateTimeOriginal             : 2017:12:28 07:14:46
CreateDate                      : 2017:12:28 07:14:46
TimeZone                        : -06:00
TimeZoneCity                  : Denver
DaylightSavings               : On
SubSecTime                     : 82
SubSecTimeOriginal          : 82
SubSecTimeDigitized         : 82
SubSecCreateDate            : 2017:12:28 07:14:46.82
SubSecDateTimeOriginal   : 2017:12:28 07:14:46.82
SubSecModifyDate           : 2017:12:28 07:14:46.82

The line I am using to try and make the needed change is:
exiftool -DateTimeOriginal+=‘1:0:1 9:0:0’ /FILE

This gets me the following changes and error:
Error: File not found - 9:0:0’
FileModifyDate                  : 2019:01:01 16:00:04-07:00
FileAccessDate                  : 2019:01:01 16:00:17-07:00
FileInodeChangeDate             : 2019:01:01 16:00:04-07:00
ModifyDate                      : 2017:12:28 07:14:46
DateTimeOriginal             : 2017:12:28 07:14:46
CreateDate                      : 2017:12:28 07:14:46
TimeZone                        : -06:00
TimeZoneCity                  : Denver
DaylightSavings               : On
SubSecTime                     : 82
SubSecTimeOriginal          : 82
SubSecTimeDigitized         : 82
SubSecCreateDate            : 2017:12:28 07:14:46.82
SubSecDateTimeOriginal   : 2017:12:28 07:14:46.82
SubSecModifyDate           : 2017:12:28 07:14:46.82

So, I am clearly doing something incorrect as the metadata is saying I modified the image to today.
I want to modify the following by adding 1 year and 9 hours
ModifyDate                      : 2017:12:28 07:14:46
DateTimeOriginal             : 2017:12:28 07:14:46
CreateDate                      : 2017:12:28 07:14:46

Once I am successful with one image I will then do a batch process to the directory.

Any information would be appreciated and let me know if I can provide anymore details.
Thanks!
Title: Re: Help needed on modifying DateTimeOriginal on Canon CR2 Images
Post by: StarGeek on January 01, 2019, 08:24:11 PM
Your command is ok, but you're using fancy quotes ‘ ’
You want to make sure you're using regular quotes '

If you're copy/pasting to a word processor or a Google doc, you'll have to make sure of the quotes, as word processors/Google will "help" you by automatically changing them for you.  OS X also has a setting (https://www.iclarified.com/38772/how-to-disable-curly-quotes-in-mac-os-x-mavericks) that will do the same.
Title: Re: Help needed on modifying DateTimeOriginal on Canon CR2 Images
Post by: Smajors on January 01, 2019, 09:11:54 PM
Thanks- made that adjustment and worked.

I ran exiftool -AllDates+='1:0:0 9:0:0' /File
It made the appropriate changes as seen below. However, when viewing files in the folders these files are still showing as today (image attached) when I try to Arrange By Date Created. This might be more of a MAC OS issue but any suggestions appreciated.

FileModifyDate                  : 2019:01:01 18:55:31-07:00
FileAccessDate                  : 2019:01:01 18:55:31-07:00
FileInodeChangeDate        : 2019:01:01 18:55:31-07:00
ModifyDate                      : 2018:12:28 16:14:18
DateTimeOriginal              : 2018:12:28 16:14:18
CreateDate                      : 2018:12:28 16:14:18
TimeZone                        : -06:00
TimeZoneCity                  : Denver
DaylightSavings               : On
SubSecTime                    : 39
SubSecTimeOriginal           : 39
SubSecTimeDigitized         : 39
SubSecCreateDate            : 2018:12:28 16:14:18.39
SubSecDateTimeOriginal    : 2018:12:28 16:14:18.39
SubSecModifyDate             : 2018:12:28 16:14:18.39
Title: Re: Help needed on modifying DateTimeOriginal on Canon CR2 Images
Post by: Phil Harvey on January 02, 2019, 07:17:53 AM
On Mac, the only way to preserve the file creation date is to use the -overwrite_original_in_place option.  See the application documentation (http://owl.phy.queensu.ca/~phil/exiftool/exiftool_pod.html) for details.

- Phil