ExifTool Forum

ExifTool => Newbies => Topic started by: AlbertosJKL on May 20, 2025, 06:41:06 AM

Title: Which Priority in Reading Duplicate tags?
Post by: AlbertosJKL on May 20, 2025, 06:41:06 AM
Hello guys, I've seen in the documentation how priority is handled when writing a tag that exists in multiple places (like Exif and XMP).

But what about display of duplicate tags at reading (when -a is not specified, of course)?
If the tag has the same value everywhere, no importance, but in the case the tag has different values? In such a case, which one preferred, and displayed?

Thank you..
Title: Re: Which Priority in Reading Duplicate tags?
Post by: StarGeek on May 20, 2025, 10:23:01 AM
For the most part, it's the last tag read, though I think there are a few exceptions. The Composite tags (https://exiftool.org/TagNames/Composite.html) are the last tags in the queue, because they depend upon the values of other tags. So if there's a Composite tag with the same name, it will be the one displayed. This is most prominent in the GPS tags such as GPSLatitude/GPSLongitude. The GPS tags in EXIF are split into two separate tags, which makes them less useful because they won't display the hemisphere. But the Composite tags combine them for the output, creating a useful coordinate.

There's a previous thread where I was dealing with how Windows reads the metadata in the file for the Properties window, and I was getting conflicting results. The takeaway was how to figure out the order of tags in the file using the -v (-verbose) option (https://exiftool.org/exiftool_pod.html#v-NUM--verbose).
Title: Re: Which Priority in Reading Duplicate tags?
Post by: Phil Harvey on May 20, 2025, 12:59:06 PM
The exceptions to the rule StarGeek mentioned are generally for cases where one version of the tag is obviously more important, then it may take priority even if it comes earlier.

- Phil