pur:expirationDate with date and qualifier

Started by t1m081, August 27, 2020, 08:02:17 AM

Previous topic - Next topic

t1m081

Hi

I am new and hope this is not a very stupid question. I am currently prototyping a command to be used to write pur:expirationDate XMP elements to files. In the http://www.prismstandard.org/specifications/3.0/PRISM_Usage_Rights_Metadata_3.0.htm#_Toc336963261 prism documentation for this element I read that it is recommended to use the Qualifier distributionChannel to distinguish expiration dates by channel. This is actually pretty much what is needed in my specific case.

However when I try to add the Tag with distributionChannel ...

exiftool -addtagsfromfile @ "-XMP-pur:expirationDate={distributionChannel=print, Date=2022-12-31}" "-XMP-pur:expirationDate={distributionChannel=web, Date=2099-12-31}" filename.jpg

it looks like only the date(s) information gets written – not not the channel itself.

Output for
exiftool -expirationDate -struct filename.jpg

Expiration Date                 : 2022:12:31

Output for
exiftool -xmp -b filename.jpg
suggests that writing multiple dates does indeed work but without the qualifier it is of little use to me  :-\


<rdf:Description rdf:about=''
  xmlns:pur='http://prismstandard.org/namespaces/prismusagerights/2.1/'>
  <pur:expirationDate>
   <rdf:Bag>
    <rdf:li>2022-12-31</rdf:li>
    <rdf:li>2022-12-31</rdf:li>
    <rdf:li>2099-12-31</rdf:li>
   </rdf:Bag>
  </pur:expirationDate>
</rdf:Description>


Am I doing something wrong? Or is this not supported in exiftool?

Thank you in advance!
Timo

StarGeek

If you take a look at the XMP-pur listing, you'll see that exiftool will only accept a Date formatted string for that tag.

This will probably require Phil's attention as to any possible changes.  Unfortunately, he's currently on vacation until early September.

If you have an example file from another source that has the distribution channel already in it, that probably would be helpful.  Or even just the extracted XMP (use exiftool -b -XMP File.jpg to get the embedded XMP) posted here would probably work.
"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

t1m081

Thank you for the quick reply. I feared that would be the case but was hoping I did something wrong.

Unfortunately I don't have any example images that have the desired format in it. Just going by the documentation about prism standard I was hoping it is possible. We are managing expiration dates by channel in a database and during export / publishing would like to write the info into the image. Would that be possible – still using the pur:expirationDate tag – with a custom configuration file that allows a qualifier in it?


StarGeek

Yes, you could create a config file to override exiftool's base definition, though that would be beyond my ability in this case.

I just noticed that your link included some details as to what is supposed to be done (XMP Qualifer distributionChannel=) so Phil can probably make sense of it when he gets back.
"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

Implementing XMP qualifiers is on my list of things to do.  Unfortunately, this will not be a simple addition.

(It had fallen to item 222 out of 558 on the to-do list, but I have bumped it up to the top now.)

- 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 ($).

t1m081

Thanks Phil!

This is going to be very useful in our case. I'll check back periodically to see if it is available. In the meantime we are going to work around this.