Subject: RE: [xsl] Multiple search From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx> Date: Thu, 20 Jun 2002 23:58:23 +0100 |
Your stylesheet has a duplicate global variable declaration which I deleted; after that correction, it ran in 621 milliseconds on Saxon. Michael Kay Software AG home: Michael.H.Kay@xxxxxxxxxxxx work: Michael.Kay@xxxxxxxxxxxxxx > -----Original Message----- > From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx > [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of > Wampler, David > Sent: 19 June 2002 13:51 > To: 'xsl-list@xxxxxxxxxxxxxxxxxxxxxx' > Subject: RE: [xsl] Multiple search > > > <xsl:stylesheet > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > version="1.0"> > > <xsl:output method="xml"/> > <xsl:param name="LoanID" select="'*'"/> > <xsl:param name="LoanPurpose" select="'*'"/> > <xsl:param name="InternalOrginization" select="'*'"/> > <xsl:param name="LoanStage" select="'*'"/> <xsl:param > name="PlacedDate" select="'*'"/> <xsl:param > name="ClosingDropDeadDate" select="'*'"/> <xsl:param > name="FundedDate" select="'*'"/> <xsl:param name="PropertyID" > select="'*'"/> <xsl:param name="PropertyName" select="'*'"/> > <xsl:param name="PropertyType" select="'*'"/> <xsl:param > name="SubPropertyType" select="'*'"/> <xsl:param > name="BorrowerName" select="'*'"/> <xsl:param > name="LoanAmount" select="'*'"/> <xsl:param name="DSCRActual" > select="'*'"/> <xsl:param name="DSCR10Constant" > select="'*'"/> <xsl:param name="ActualLTV" select="'*'"/> > <xsl:param name="LoanTerm" select="'*'"/> <xsl:param > name="AmortizationPeriod" select="'*'"/> <xsl:param > name="QuotedSpreadRate" select="'*'"/> <xsl:param > name="IndexType" select="'*'"/> <xsl:param name="LoanFee" > select="'*'"/> > > > <xsl:variable name="LoanIDNodes" > select="Pipelines/Pipeline[$LoanID!='*'][LoanID=$LoanID]|Pipel > ines/Pipeline[ > $LoanID='*']"/> > > <xsl:variable name="LoanPurposeNodes" > select="$LoanIDNodes[$LoanPurpose!='*'][LoanPurpose=$LoanPurpo > se]|$LoanIDNod > es[$LoanPurpose='*']"/> > > <xsl:variable name="InternalOrginizationNodes" > select="$LoanPurposeNodes[$InternalOrginization!='*'][Internal Orginization=$ > InternalOrginization]|$LoanPurposeNodes[$InternalOrginization='*']"/> > > <xsl:variable name="LoanStageNodes" > select="$InternalOrginizationNodes[$LoanStage!='*'][LoanStage= > $LoanStage]|$I > nternalOrginizationNodes[$LoanStage='*']"/> > > <xsl:variable name="PlacedDateNodes" > select="$LoanStageNodes[$PlacedDate!='*'][PlacedDate=$PlacedDa > te]|$LoanStage > Nodes[$PlacedDate='*']"/> > > <xsl:variable name="ClosingDropDeadDateNodes" > select="$PlacedDateNodes[$ClosingDropDeadDate!='*'][ClosingDro > pDeadDate=$Clo > singDropDeadDate]|$PlacedDateNodes[$ClosingDropDeadDate='*']"/> > > <xsl:variable name="FundedDateNodes" > select="$ClosingDropDeadDateNodes[$FundedDate!='*'][FundedDate > =$FundedDate]| > $ClosingDropDeadDateNodes[$FundedDate='*']"/> > > <xsl:variable name="PropertyIDNodes" > select="$FundedDateNodes[$PropertyID!='*'][PropertyID=$Propert > yID]|$FundedDa > teNodes[$PropertyID='*']"/> > > <xsl:variable name="PropertyNameNodes" > select="$PropertyIDNodes[$PropertyName!='*'][PropertyName=$Pro > pertyName]|$Pr > opertyIDNodes[$PropertyName='*']"/> > > <xsl:variable name="PropertyTypeNodes" > select="$PropertyNameNodes[$PropertyType!='*'][PropertyType=$P > ropertyType]|$ > PropertyNameNodes[$PropertyType='*']"/> > > <xsl:variable name="SubPropertyTypeNodes" > select="$PropertyTypeNodes[$SubPropertyType!='*'][SubPropertyT > ype=$SubProper > tyType]|$PropertyTypeNodes[$SubPropertyType='*']"/> > > <xsl:variable name="BorrowerNameNodes" > select="$SubPropertyTypeNodes[$BorrowerName!='*'][BorrowerName > =$BorrowerName > ]|$SubPropertyTypeNodes[$BorrowerName='*']"/> > > <xsl:variable name="SubPropertyTypeNodes" > select="$PropertyTypeNodes[$SubPropertyType!='*'][SubPropertyT > ype=$SubProper > tyType]|$PropertyTypeNodes[$SubPropertyType='*']"/> > <xsl:variable name="LoanAmountNodes" > select="$SubPropertyTypeNodes[$LoanAmount!='*'][LoanAmount=$Lo > anAmount]|$Sub > PropertyTypeNodes[$LoanAmount='*']"/> > > <xsl:variable name="DSCRActualNodes" > select="$LoanAmountNodes[$DSCRActual!='*'][DSCRActual=$DSCRAct > ual]|$LoanAmou > ntNodes[$DSCRActual='*']"/> > > <xsl:variable name="DSCR10ConstantNodes" > select="$DSCRActualNodes[$DSCR10Constant!='*'][DSCR10Constant= > $DSCR10Constan > t]|$DSCRActualNodes[$DSCR10Constant='*']"/> > > <xsl:variable name="ActualLTVNodes" > select="$DSCR10ConstantNodes[$ActualLTV!='*'][ActualLTV=$Actua > lLTV]|$DSCR10C > onstantNodes[$ActualLTV='*']"/> > > <xsl:variable name="LoanTermNodes" > select="$ActualLTVNodes[$LoanTerm!='*'][LoanTerm=$LoanTerm]|$A > ctualLTVNodes[ > $LoanTerm='*']"/> > > <xsl:variable name="AmortizationPeriodNodes" > select="$LoanTermNodes[$AmortizationPeriod!='*'][AmortizationP > eriod=$Amortiz > ationPeriod]|$LoanTermNodes[$AmortizationPeriod='*']"/> > > <xsl:variable name="QuotedSpreadRateNodes" > select="$AmortizationPeriodNodes[$QuotedSpreadRate!='*'][Quote > dSpreadRate=$Q > uotedSpreadRate]|$AmortizationPeriodNodes[$QuotedSpreadRate='*']"/> > > <xsl:variable name="IndexTypeNodes" > select="$QuotedSpreadRateNodes[$IndexType!='*'][IndexType=$Ind > exType]|$Quote > dSpreadRateNodes[$IndexType='*']"/> > > <xsl:variable name="LoanFeeNodes" > select="$IndexTypeNodes[$LoanFee!='*'][LoanFee=$LoanFee]|$Inde > xTypeNodes[$Lo > anFee='*']"/> > > > > > <xsl:template match="/"> > <Pipelines> > <xsl:call-template name="Pipeline1"/> > </Pipelines> > </xsl:template> > > > <xsl:template name="Pipeline1"> > <Pipeline> > <xsl:copy-of select="$LoanFeeNodes"/> > </Pipeline> > </xsl:template> > > > > > </xsl:stylesheet> > > -----Original Message----- > From: Michael Kay [mailto:michael.h.kay@xxxxxxxxxxxx] > Sent: Tuesday, June 18, 2002 4:15 AM > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > Subject: RE: [xsl] Multiple search > > > > well since it was a performance based problem, i thought > you meant CPU > > > > Xalan > > > Well, either (1) try it on another processor and see if you > get the same results, or (b) post the full stylesheet and XML > source here, and see whether anyone else can get it to work. > You could also try allocating more memory (assuming you are > using Xalan-Java, see the options for the java command line). > > It may be that your stylesheet has a non-terminating > recursion, or it may simply be that it needs more memory, or > it may be that for some reason Xalan is executing this > particular code inefficiently. > > > > Thanks > > > > -----Original Message----- > > From: Joerg Heinicke [mailto:joerg.heinicke@xxxxxx] > > Sent: Monday, June 17, 2002 2:54 PM > > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > > Subject: Re: [xsl] Multiple search > > > > > > Yes, it was a good laugher. > > > > David, not the CPU was meant, but the XSLT processor. > > > > Joerg > > > > Andrew Welch wrote: > > >>I'm using a P4 1.7 GHz, so it can't be that problem. > > > > > > > > > Thanks David, you've cheered up my monday afternoon > > > > > > > > > -----Original Message----- > > > From: Michael Kay [mailto:michael.h.kay@xxxxxxxxxxxx] > > > > > > Which processor are you using? I can't see anything wrong with the > > > code > > > - see if you get the same problem with a different processor. > > > > > > Michael Kay > > > > > >>-----Original Message----- > > >>From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx > > >>[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of > > >>Wampler, David > > >> > > >>I've encountered an out of memory problem with the following > > >>template. Basically I just want to be able to search for 20 > > >>different parameters. The results depend on all parameters. > > >> > > >><xsl:stylesheet > > >> xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > > >> version="1.0"> > > >> > > >><xsl:output method="xml"/> > > >><xsl:param name="Element1" select="'*'"/> > > >><xsl:param name="Element2" select="'*'"/> > > >><xsl:param name="Element3" select="'*'"/> > > >>....continues for 20 parameters. > > >> > > >><xsl:variable name="Element1Nodes" > > >>select="Pipelines/Pipeline[$Element1!='*'][Element1=$Element1] > > >>|Pipelines/Pip > > >>eline[$Element1='*']"/> > > >><xsl:variable name="Element2Nodes" > > >>select="$Element1Nodes[$Element2!='*'][Element2=$Element2]|$El > > >>ement1Nodes[$E > > >>lement2='*']"/> > > >><xsl:variable name="Element3Nodes" > > >>select="$Element2Nodes[$Element3!='*'][Element3=$Element3]|$El > > >>ement2Nodes[$E > > >>lement3='*']"/> > > >>.....continues for 20 parameters > > >> > > >><xsl:template match="/"> > > >><Pipelines> > > >><xsl:call-template name="Pipeline1"/> > > >></Pipelines> > > >></xsl:template> > > >> > > >><xsl:template name="Pipeline1"> > > >><Pipeline> > > >><xsl:copy-of select="$Element3Nodes"/> > > >></Pipeline> > > >></xsl:template> > > >> > > >></xsl:stylesheet> > > >> > > >> > > >> > > >>xml looks like this.... > > >> > > >><Pipelines> > > >><Pipeline> > > >> <Element1>data</Element1> > > >> <Element2>data</Element2> > > >> <Element3>data</Element3> > > >></Pipeline> > > >><Pipeline> > > >> <Element1>data</Element1> > > >> <Element2>data</Element2> > > >> <Element3>data</Element3> > > >></Pipeline> > > >></Pipelines> > > >> > > >>The user can enter any or all parameters. If none are > entered, it > > >>assumes that it will display * (all) for each element. > Any help is > > >>greatly appreciated. > > >> > > >> > > >>Thanks. > > > > > > XSL-List info and archive: > http://www.mulberrytech.com/xsl/xsl-list > > > > XSL-List info > and archive: http://www.mulberrytech.com/xsl/xsl-list > > > > > > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Multiple search, Jeni Tennison | Thread | RE: [xsl] Multiple search, Andrew Welch |
Re: [xsl] XSLT Table defination Que, Joerg Heinicke | Date | RE: [xsl] Urgent-how to select node, Michael Kay |
Month |