Created
May 4, 2020 21:55
-
-
Save kschlottmann/05e1a19c7fe3de34a66df670d24b1e18 to your computer and use it in GitHub Desktop.
xquery to retrieve series level titles with the string '19' (proxy for selecting finding aids with dates in unittitles)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <data> | |
| { | |
| for $Record in /ead | |
| where $Record/archdesc/dsc//c[@level='series']/did/unittitle[contains(., '19')] | |
| let $id := $Record/archdesc/did/unitid[1]/text() | |
| let $title := $Record/archdesc/did/unittitle | |
| let $repo := $Record/eadheader/eadid/@mainagencycode | |
| return | |
| <record> | |
| <id>{data($id)}</id> | |
| <repo>{data($repo)}</repo> | |
| <title>{data($title)}</title> | |
| </record> | |
| } | |
| </data> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment