On 6/26/2016 1:41 PM, Pauline Smith wrote:
> Does anyone know how to edit an xslt to take a MARC field value and put it
> into an EAD attribute?
> For example, I put the date 1990/1997 into a MARC field 999. Then I have an
> xslt to convert the MARC record to EAD in MARCEdit.  What should I put
> in the xslt to take the MARC field 999 and put it into the "normal"
> attributes of the date elements in EAD?
> Thanks!
> Pauline Smith

What's the input to your XSLT -- is it MARCXML?  If so, then you'd want 
something like this:

<xsl:for-each select="marc:datafield[@tag=999]">
       <xsl:attribute name="normal">
          <xsl:value-of select="."/>

I can't say 100% for sure that this will work without seeing your XSLT -- it may 
be looking at other fields for <unitdate> as well.  For example, if it's looking 
at 245 subfield f, then instead of a separate match for 999 as shown above, 
you'd have to add it into that template, something like this (assuming there's 
only one 999 field):

    <xsl:if test="marc:subfield[@code='f']!=''">
       <unitdate type="inclusive" encodinganalog="245$f">
          <xsl:attribute name="normal">
             <xsl:value-of select="../marc:datafield[@tag=999"]/>
          <xsl:value-of select="marc:subfield[@code='f']" />

Those three things -— autonomy, complexity, and a connection
between effort and reward -— are, most people agree, the three
qualities that work has to have if it is to be satisfying.
      -- Malcolm Gladwell, "Outliers"