ExifTool Forum

General => Metadata => Topic started by: itsjustvenky on November 23, 2017, 11:51:49 PM

Title: Inconsistent extraction (photoshop:Category )
Post by: itsjustvenky on November 23, 2017, 11:51:49 PM
Hi, I am trying to extract <photoshop:Category> metadata from the a TIF file (https://drive.google.com/file/d/1HWuPHzsRlxdNDSGcK8skcMtWzPkVy0V0/view)
and I am finding the metadata getting truncated with following command

ExifTool : 10.67 (windows)

Command : exiftool -tagsfromfile 20140257_6918.tif output.xmp

Result :  <photoshop:Category>Pro</photoshop:Category>

But when I use the command

Command : exiftool -tagsfromfile 20140257_6918.tif -all:all output.xmp

Result : <photoshop:Category>Professional</photoshop:Category>

I am little confused on why this is happening and whats the exact difference in commands.
Please do let me know how to fix this issue.

Thanks.
Title: Re: Inconsistent extraction (photoshop:Category )
Post by: StarGeek on November 24, 2017, 01:20:05 AM
You have two Category tags in that file.  The IPTC:Catergory is the source of "Pro" and the XMP:Category has "Professional".

The IPTC:Catergory has priority between the two.  In the case of your first command, tags "from the source file are copied to same-named tags in the preferred location of the output file" (first paragraph of the docs on TagsFromFile (https://exiftool.org/exiftool_pod.html#tagsFromFile-SRCFILE-or-FMT)).  Since an .xmp file only has XMP tags, it's copied to XMP:Category.

Copying -all:all on the other hand, copies tags to the same location in the target file (see second paragraph under TagsFromFile).  If the source file didn't have the XMP:Category tag, then output.xmp would not have contained a Category tag.

As for a fix, maybe try -XMP:All.  If that's missing some data you needed from the EXIF or IPTC groups, then you'll have to take a look at your data to see what else you need to copy.  Or take a look at the IPTC2XMP.args and EXIF2XMP.args files to fill out your XMP data first.