That should have read: ...
or more readibly as: <xsl:template match="marc:subfield[@tag='710'] [@ind1='2'] [@ind2=' '] [marc:subfield [@code='a'] [ text()='Faux College']] [marc:subfield[@ code='b'] [text()='Special Collections']]"/> cheers stuart -- ...let us be heard from red core to black sky ---------- Forwarded message ---------- From: Stuart A. Yeates <syea...@gmail.com> Date: Wed, Jan 11, 2017 at 10:28 AM Subject: Re: [CODE4LIB] MARCXML help again To: Code for Libraries <CODE4LIB@lists.clir.org> You need an identity transform + a no-op template such as: <xsl:template match="marc:subfield[@tag='710'][@ind1='2'][@ind2=' '][ marc:subfield[@code='a'][text()='Faux College']][marc:subfield[@code='b'] [text()='Special Collections']]"/> or more readibly as: <xsl:template match="marc:subfield[@tag='710'] [@ind1='2'][@ind2=' '][marc:subfield[@code='a'][text()='Faux College']][ marc:subfield[@code='b'][text()='Special Collections']]"/> cheers stuart -- ...let us be heard from red core to black sky On Wed, Jan 11, 2017 at 10:13 AM, Julie Swierczek <jswie...@swarthmore.edu> wrote: > Thanks to all who responded to my earlier plea for help. I now have a new > problem. I'm not sure if I can do this with find and replace in Oxygen, or > if this requires XSLT, or what. > > I have a project of MARCXML records like this: > > <?xml version="1.0" encoding="UTF-8" ?> > <marc:collection 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"> > <marc:record> > <!--Lots of other datafields here --> > <marc:datafield tag="710" ind1="2" ind2=" "> > <marc:subfield code="a">Faux College</marc:subfield> > <marc:subfield code="b">Special Collections</marc:subfield> > </marc:datafield> > </marc:record> > </marc:collection> > > I want to strip out all instances of: > <marc:datafield tag="710" ind1="2" ind2=" "> > <marc:subfield code="a">Faux College</marc:subfield> > <marc:subfield code="b">Special Collections</marc:subfield> > </marc:datafield> > but I want to leave other <marc:datafield tag="710" ind1="2" ind2=" "> > instances intact. I only want to delete ones with both the Faux College > and Special Collections text in the subfields. > > Where would I go from here? I thought of doing an xsl:template match in an > XSL stylesheet, and then not providing any instructions for replacing the > match, but I don't know how to select for that specific text. My attempts > to figure that out have not worked. You can only read so much W3C > documentation and Stack Overflow before you need to just sit quietly and > stare at a wall for a while. > > Thanks in advance -- > > Julie >