Same name sibling elements
Posted: Tue Feb 15, 2005 1:54 am
How can i write a single XSL that will get cpad from under cpadPtAddr and cpad from under cpadPtAddrFlr and output it top a pipe delimited text file.
IO have two xsls that can do this seperately but match template works only for either cpadptAddr or cpadPtAddrFLr
IO have two xsls that can do this seperately but match template works only for either cpadptAddr or cpadPtAddrFLr
Code: Select all
<?xml version="1.0"?>
<te>
<add>
<alp>45</alp>
<aun>01</aun>
<seq>401C</seq>
<apr/>
<asu/>
<alo>6802</alo>
<ahi>6811</ahi>
<loF>1</loF>
<hiF>15</hiF>
<asn>RUSTICA</asn>
<ri>1</ri>
<con>0</con>
<cn>65</cn>
<city>
<cinm>WESTMINSTER</cinm>
</city>
<zip>
<code>21158</code>
<cmt>2</cmt>
</zip>
<urb>
<unm/>
</urb>
<st>
<stnm>MD</stnm>
</st>
<typ>CIR</typ>
<rla>0</rla>
<cds>0</cds>
<rlex>
<ri>2</ri>
<stnm>6804</stnm>
</rlex>
<cpadPtAddr>
<cpadStrNum>6804</cpadStrNum>
<CPaD>
<cpadMsgID>4</cpadMsgID>
<cpadMsgType>20</cpadMsgType>
<cpadExtMsg>ENTERTHECODE</cpadExtMsg>
<cpadNAP>100</cpadNAP>
<cpadDIADDecides>0</cpadDIADDecides>
<cpadDays>0111111</cpadDays>
<cpadStartDate/>
<cpadEndDate/>
</CPaD>
</cpadPtAddr>
<cpadPtAddrFlr>
<cpadStrNum>6804</cpadStrNum>
<cpadFlr>15</cpadFlr>
<CPaD>
<cpadMsgID>15</cpadMsgID>
<cpadMsgType>20</cpadMsgType>
<cpadExtMsg>BRING BACK</cpadExtMsg>
<cpadNAP>100</cpadNAP>
<cpadDIADDecides>0</cpadDIADDecides>
<cpadDays>0111111</cpadDays>
<cpadStartDate/>
<cpadEndDate/>
</CPaD>
</cpadPtAddrFlr>
</add>
</te>