ExifTool Forum

General => Metadata => Topic started by: c0mplicated on September 04, 2018, 02:12:43 PM

Title: Updating FileModifyDate does not work (unchanged)
Post by: c0mplicated on September 04, 2018, 02:12:43 PM
I would like to overwrite a FileModifyDate entry with a ModifyDate entry of an image to keep the correct order.
I used the following command to do that:
-v5 -d "%Y:%m:%d %H:%M:%S" "-FileModifyDate<ModifyDate" "/storage/emulated/0/DCIM/Camera-Temp-1/Camera/IMAG0001.jpg"

But I get a "nothing changed" response.

NOTE:
ExifTool is running on my Android 8 devices by means of the app "ExifTool" from "Oleg A"...

I hope someone can help me,

thanks!
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: Phil Harvey on September 04, 2018, 04:01:40 PM
You will get this message if the file doesn't contain a "ModifyDate" tag.  Use this command to see what date/time tags are available:

exiftool -a -G1 -s -time:all FILE

- Phil
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: c0mplicated on September 04, 2018, 05:15:34 PM
Thank you for your answer!

But it seems to have that tag... (see attachment)
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: StarGeek on September 04, 2018, 05:28:53 PM
Since this is on an Android system, maybe that implantation of perl doesn't have the appropriate routines to change system timestamps?

Are you able to directly set the FileModifyDate?
exiftool "-FileModifyDate=2018:09:04 23:12:19" File

Also, the -d option (https://exiftool.org/exiftool_pod.html#d-FMT--dateFormat) can be removed from this command, it isn't necessary.  See FAQ #5 (https://exiftool.org/faq.html#Q5), third paragraph.
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: c0mplicated on September 04, 2018, 05:46:41 PM
When I use the command you posted, I am always getting the attached error message. (su is on)
So I tried to set the -d option to avoid this message, which did not help...
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: StarGeek on September 05, 2018, 02:29:30 AM
How about if you drop all formatting
exiftool -FileModifyDate=20180904231219 File

Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: c0mplicated on September 05, 2018, 05:54:53 AM
Unfortunatelly the same error...

The command -FileModifyDate "/storage/emulated/0/2011-12-30 15-38-40 - IMAG0108.jpg" returns File Modification Date/Time     : 2018:09:04 23:40:47+02:00.

But when i use the command "-FileModifyDate=2018:09:04 23:12:19+02:00" "/storage/emulated/0/2011-12-30 15-38-40 - IMAG0108.jpg" it returns the same "Error converting Value for File..." error  ::)
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: Phil Harvey on September 05, 2018, 06:38:26 AM
It would be useful if you gave the exact error message.

If the error is in the PrintConvInv, then try adding -n to the command.  If it is in the ValueConvInv, then the problem may be that Time::Local isn't available or isn't working.  Be sure this module is installed.

- Phil
Title: Re: Updating FileModifyDate does not work (unchanged)
Post by: c0mplicated on September 05, 2018, 07:40:30 AM
Sorry for being unspecific, it was the "ValueConvInv" error.

Is there a exiftool command to test if module "Time::Local" is installed?
I don't have pearl installed dierctly on Android...

EDIT:
I have found the App "File Timestamp" from "PogSoft" which does exactly what I need (copying the EXIF entry for capture date to the modified date entry for all files).
So solving this problem is relevant for other/interest only...