Subject: Re: [xsl] Help with staregies for outputting an incremental number in xslt From: Adam Lipscombe <adam.lipscombe@xxxxxxxxxx> Date: Thu, 29 Nov 2007 16:45:36 +0000 |
> Incidentally, please don't do this: > >> <xsl:variable name="description"> >> <xsl:value-of select="../../expensys:ItemDescription"/> >> </xsl:variable> > > when you mean this: > >> <xsl:variable name="description" > select="../../expensys:ItemDescription"/>
<Transaction transactionType="CorporateCardReconciliation"> <Header> <TransactionIdentifier><![CDATA[CC-DD101-S1]]></TransactionIdentifier> <EnterpriseLevel><![CDATA[ACME Engineering]]></EnterpriseLevel> <ClaimantName><![CDATA[Dolores Delegate]]></ClaimantName> <ClaimantIdentifier><![CDATA[DD101]]></ClaimantIdentifier> <Description><![CDATA[BarclayCard Statement: 01/02/2007]]></Description> <Currency><![CDATA[GBP]]></Currency> <CreationDate><![CDATA[2007-11-29T00:00:00+00:00]]></CreationDate> <ApprovedDate><![CDATA[2007-11-29T00:00:00+00:00]]></ApprovedDate> <ProcessedDate><![CDATA[2007-11-29T00:00:00+00:00]]></ProcessedDate> <TransactionAmount> <value><![CDATA[20.00]]></value> <sense><![CDATA[credit]]></sense> </TransactionAmount> <Approvers> <Approver><![CDATA[Eddie Executive]]></Approver> </Approvers> <StatementDate><![CDATA[2007-02-01T00:00:00+00:00]]></StatementDate> <StatementAmount><![CDATA[35.00]]></StatementAmount> <CorporateCardSettlementType><![CDATA[personal]]></CorporateCardSettlementType> </Header> <Lines> <Line> <ItemDescription><![CDATA[Personal Spend]]></ItemDescription> <ItemNumber><![CDATA[1]]></ItemNumber> <SpendDate><![CDATA[2007-01-08T00:00:00+00:00]]></SpendDate> <CostCentre> <costCentreCode><![CDATA[CC1]]></costCentreCode> </CostCentre> <ProjectCode><![CDATA[CODE01]]></ProjectCode> <Accruals> <Accrual> <accountCode><![CDATA[999998]]></accountCode> <amount> <value><![CDATA[15.00]]></value> <sense><![CDATA[debit]]></sense> </amount> </Accrual> </Accruals> </Line> <Line> <ItemDescription><![CDATA[test dol]]></ItemDescription> <ItemNumber><![CDATA[2]]></ItemNumber> <SpendDate><![CDATA[2007-01-08T00:00:00+00:00]]></SpendDate> <CostCentre> <costCentreCode><![CDATA[CC1]]></costCentreCode> </CostCentre> <ProjectCode><![CDATA[CODE01]]></ProjectCode> <Accruals> <Accrual> <accountCode><![CDATA[100102]]></accountCode> <amount> <value><![CDATA[20.00]]></value> <sense><![CDATA[debit]]></sense> </amount> </Accrual> </Accruals> </Line> </Lines> </Transaction>
I don't understand what you mean by "omitted nodes" (I have trouble discussing non-existent objects). If position() counts it, then it must be there. Please show us your XML to illustrate what you are talking about.
Incidentally, please don't do this:
<xsl:variable name="description"> <xsl:value-of select="../../expensys:ItemDescription"/> </xsl:variable>
when you mean this:
<xsl:variable name="description"select="../../expensys:ItemDescription"/>
It's the kind of thing that gives XSLT an undeserved reputation for being verbose and slow.
Michael Kay http://www.saxonica.com/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Help with staregies for o, Michael Kay | Thread | RE: [xsl] Help with staregies for o, Michael Kay |
RE: [xsl] include error, Scott Trenda | Date | RE: [xsl] Help with staregies for o, Michael Kay |
Month |