String to Nodelist
Here should go questions about transforming XML with XSLT and FOP.
-
- Posts: 2
- Joined: Thu Nov 03, 2005 4:49 am
String to Nodelist
Hi....
I've XML schema as shown below:
\
<UI_BeneficiaryInfo>
<PrimaryBeneficiary>
<Beneficiary1>
<Name/>
<Relationship/>
<PercentDesignated/>
</Beneficiary1>
<Beneficiary2>
<Name/>
<Relationship/>
<PercentDesignated/>
</Beneficiary2>
</PrimaryBeneficiary>
</UI_BeneficiaryInfo>
I've to display the 2 rows corresponding to Beneficiary. Each row will contain name, relationship & percent. I was able to display these rows but I couldn't assign the XPATH to them. I've a written a loop to display these rows & when I'm concatenating the XPATH with Beneficiary & then appending 1, 2 ....through for-loop, I'm getting an exception, since it bacame the string after concatenation. What I need is a value & not a string. Can anyone help?
I've XML schema as shown below:
\
<UI_BeneficiaryInfo>
<PrimaryBeneficiary>
<Beneficiary1>
<Name/>
<Relationship/>
<PercentDesignated/>
</Beneficiary1>
<Beneficiary2>
<Name/>
<Relationship/>
<PercentDesignated/>
</Beneficiary2>
</PrimaryBeneficiary>
</UI_BeneficiaryInfo>
I've to display the 2 rows corresponding to Beneficiary. Each row will contain name, relationship & percent. I was able to display these rows but I couldn't assign the XPATH to them. I've a written a loop to display these rows & when I'm concatenating the XPATH with Beneficiary & then appending 1, 2 ....through for-loop, I'm getting an exception, since it bacame the string after concatenation. What I need is a value & not a string. Can anyone help?
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hi,
If you want to use standard XSLT then the solution is to split the transformation in a couple of steps. For instance you can apply a stylesheet S1 on your XML data that will generate also a styelsheet, let's say S2. Then you apply S2 on the XML data and get your final output. In this way you can generate with S1 code that will be considered as XSLT code in the second step.
If you do not have problems with a certain XSLT processor dependency then you can use that processor evaluate extension if available, for instance Saxon has such an extension function:
http://saxon.sourceforge.net/saxon6.5.4 ... l#evaluate
Best Regards,
George
If you want to use standard XSLT then the solution is to split the transformation in a couple of steps. For instance you can apply a stylesheet S1 on your XML data that will generate also a styelsheet, let's say S2. Then you apply S2 on the XML data and get your final output. In this way you can generate with S1 code that will be considered as XSLT code in the second step.
If you do not have problems with a certain XSLT processor dependency then you can use that processor evaluate extension if available, for instance Saxon has such an extension function:
http://saxon.sourceforge.net/saxon6.5.4 ... l#evaluate
Best Regards,
George
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service