[librecat-dev] question regarding Fix language
Nicolas Steenlant
Nicolas.Steenlant at UGent.be
Mon Oct 21 13:30:17 CEST 2019
This will give you the last embargo value encountered:
cp(file.*.embargo, embargo)
If you need the all values:
cp(file.*.embargo, embargo.$append)
If you need the first value:
cp(file.*.embargo, tmp.$append)
cp(tmp.$first, embargo)
rm(tmp)
Greets,
Nicolas
---
Nicolas Steenlant
Ghent University Library
> On 21 Oct 2019, at 13:21, Jonathan NORRIS <jnorris at ist.ac.at> wrote:
>
> Hello,
>
> I could not find the answer in the fix documentation so maybe some of you can help me. I am editing the 'to_dc.fix' to add the embargo end date field. Considering that the embargo end date is in the 'file' section of the publication and there can be multiple files, I just need to get the 'embargo' value from any of the files that contain an 'embargo' field. Does anyone know if you can search for a field and return the first value you find for that field? For example:
>
> file:
> - access_level: open
> file_id: 1
> - access_level: closed
> file_id: 2
> embargo: 2020-01-01
> - access_level: closed
> file_id: 3
> embargo: 2020-01-01
>
> I just want to return the value of the first possible embargo field.
>
> Thanks for any help!
> Jonathan
> IST Austria
> _______________________________________________
> librecat-dev mailing list
> - send list mails to librecat-dev at lists.uni-bielefeld.de
> - to unsubscribe or change options, visit https://lists.uni-bielefeld.de/mailman2/cgi/unibi/listinfo/librecat-dev
> - project website: http://librecat.org/
More information about the librecat-dev
mailing list