I have data like:
<td>USERID</td>
<td>NAME</td>
<td>RATING</td>
I want to transform it into:
<userid></userid>
<name></name>
<rating></rating>
How can I do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Use a computed element constructor to generate an element with the
lower-casevalue of thetextnodes for each of thetdelements.For the sake of the example, assuming that your XML is in a file called foo.xml, you could do something like this:
to produce this:
You could also evaluate the
lower-case()function as part of the XPATH expression instead of the element constructor, like this: