Odd message:"Warning: Tag 'ProvinceState' does not exist"

Started by L_Carver, February 08, 2017, 02:25:54 AM

Previous topic - Next topic

L_Carver

I see on the page listing XMP tags that 'ProvinceState' is in the "iptcExt" list, so why am I getting this error?

standout, with data called from a file formatted to use readline, looks like this:
carver@carver-vostro-1720 unsorted $ mapfile -t msallen<realnimuelocation
carver@carver-vostro-1720 unsorted $ file0=${msallen[0]}
carver@carver-vostro-1720 unsorted $ echo $file0
nimue4319.jpg
carver@carver-vostro-1720 unsorted $ city=${msallen[1]}
carver@carver-vostro-1720 unsorted $ prov=${msallen[2]}
carver@carver-vostro-1720 unsorted $ country=${msallen[3]}
carver@carver-vostro-1720 unsorted $ echo $city
London
carver@carver-vostro-1720 unsorted $ echo $prov
England
carver@carver-vostro-1720 unsorted $ echo $country
United Kingdom
carver@carver-vostro-1720 unsorted $ tool -City="$city" -ProvinceState="$prov" -Country="$country" $file0
    1 image files updated

I haven't take it any further than this, but per usual I've considered writing a bash script to handle text source files line-by-line in just this way.  Do I have to specify the XMP tag I'm trying to use in this instance, as in XMP-iptc-Ext:ProvinceState, or is my install of Exiftool just being flukey? (10.10 in LinuxMint 8.2 Serena)

Carver
____________
Screen name comes from a story my ex-wife and I worked on for several years and never got past the first chapter. Llewellyn Carver was a Welsh drow elf living somewhere in New York state. Message me if you're curious to find out more.

StarGeek

I believe that it's part of the LocationDetails Structured data, which is the format of other tags, such as LocationCreated, LocationShown, and RatingRatingRegion.  In this case, it looks like it can't be written as a flattened tag, only as part of the structure.  See the Structured Information.

I could be wrong though, I have trouble wrapping my head around the whole structured tag stuff.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

Phil Harvey

StarGeek is correct.   ProvinceState is a structure element, not a tag.  It is used in either a LocationCreated, LocationShown or RatingRegion structure.  So you need to write LocationCreatedProvinceState, LocationShownProvinceState or RatingRegionProvinceState.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

StarGeek

And correct me if I'm wrong, Phil, but it can't be extracted separately like an individual tag?  At least it doesn't seem to in my quick tests.  You have to extract the whole thing with the -struct option?

If so, then I'd say that this isn't the tag you want to use, L_Carver.  I think XMP:State is the tag you want, because it's the XMP version of the IPTC:Province-State tag.


Never mind, re-read your post.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype