This file contains 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
xquery version "3.0"; | |
<results> | |
{ | |
for $OAIMarcRecord in /repository/record[metadata/record/datafield[@tag="264"]] | |
let $callno:= $OAIMarcRecord/metadata/record/datafield[@tag[contains(., "09")]][1]/subfield[@code="a"] | |
let $title := $OAIMarcRecord/metadata/record/datafield[@tag="245"] | |
let $publisher := $OAIMarcRecord/metadata/record/datafield[@tag="264"] | |
let $PID := $OAIMarcRecord/header/identifier/substring-after(., "oai:digital.cjh.org:") |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:marc="http://www.loc.gov/MARC21/slim" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.loc.gov/MARC21/slim | |
http://www.loc.gov/standards/marcxml/schema/MARC21slim.xsd" version="2.0"> | |
<xsl:output method="xml"/> | |
<!-- This stylesheet was written in July 2015 to automatically add 856 fields for the LBI art project. Filenames are derived from the 094 field. KS 20150713 --> | |
<xsl:variable name="filename"> | |
<xsl:value-of select="translate(marc:collection/marc:record/marc:datafield[@tag='094']/marc:subfield[@code='a']/text(), '.', '-')"/> | |
</xsl:variable> |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xhtml="http://www.w3.org/1999/xhtml" exclude-result-prefixes="xs" version="2.0"> | |
<xsl:output omit-xml-declaration="yes"/> | |
<xsl:template match="/"> | |
<xsl:for-each select="root/a"> | |
<xsl:variable name="FA"> | |
<xsl:value-of select="."/> | |
</xsl:variable> | |
<xsl:value-of select="normalize-space(document($FA)/xhtml:html/xhtml:head/xhtml:title)"/> | |
<xsl:text>; </xsl:text> |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | |
xmlns:xs="http://www.w3.org/2001/XMLSchema" | |
exclude-result-prefixes="xs" | |
version="2.0"> | |
<xsl:template match="/"> | |
<xsl:for-each select="document('PIDsforEADs.xml')/record/pid"> | |
<record> | |
<xsl:variable name="PID" select="."></xsl:variable> |
This file contains 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
xquery version "3.0"; | |
<results> | |
{ | |
for $PIDlist in doc('OH_PIDS_XML.xml')/data/pid/text() | |
let $OAIRecord := repository/record[header/identifier/substring-after(., "oai:digital.cjh.org:") = $PIDlist] | |
return |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> | |
<!--List of PIDS --> | |
<xsl:template match="/"> | |
<xsl:for-each select="results/record/header/identifier"> | |
<xsl:copy-of select="./text()"/>, | |
</xsl:for-each> | |
</xsl:template> |
This file contains 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
#!/bin/bash | |
# This script will pull the oai feed, assign it a name based on the time and date, pull out requested data, and | |
mkdir $(date +%Y%m%d) | |
cd $(date +%Y%m%d) | |
echo "Files found in" $(date +%Y%m%d) | |
#run pythonaoi to get feed | |
python /home/kevin/test/pyoaiharvest.py -l http://digital.cjh.org/OAI-PUB -o LBI_periodicals$(date +%Y%m%d).xml -m marc21 -s LBI_periodicals | |
# sed to remove marc namespace prefix, consider using the sed 'or' to clean up other stuff in one shot |
This file contains 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
xquery version "3.0"; | |
<results> | |
{ | |
for $PIDlist in doc('OH_PIDS_XML.xml')/data/pid/text() | |
let $OAIRecord := repository/record[header/identifier/substring-after(., "oai:digital.cjh.org:") = $PIDlist] | |
return |
This file contains 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
xquery version "3.0"; | |
declare namespace xb="http://com/exlibris/digitool/repository/api/xmlbeans"; | |
<data> | |
{ | |
for $Record in /xb:digital_entity_call | |
let $PID := $Record/xb:digital_entity/pid | |
let $arrecord := $Record/xb:digital_entity/mds/md[type[contains (., 'rights_md')]] | |
return |
This file contains 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
Sub Digitool_KDP_based_ingest_LBI_AR5() | |
' | |
' This macro will take a basic Karens Directory Printer output and prepare a template for Digitool CSV ingest. 100214 KS with updates by LL for LBI Creekside collections with five digits after the AR 2014-11-21 | |
' | |
' | |
' RenameSheet Macro | |
' | |
' |