Subject:Manipulation of XQuery output!! Author:Raghav Tulshibagwale Date:17 Nov 2008 02:57 PM
Hello ...
I have the following code as a query ..
"
let $cust :=doc("customers.xml")/Customer-Information/Customer
for $x in $cust
let $y := $x/cust_phn_numbers
return <p>{$x} has phones {$y}</p>
"
If I use the above code it gives me correct answer, but has the <p></p> tags for every customer. I want the answer without the tags. If I remove the tags it gives error.
Can anyone put some light on how to solve the issue??
Also let me know how to get the results on subsequent lines instead of the results displayed one after the other??
Subject:Manipulation of XQuery output!! Author:Raghav Tulshibagwale Date:17 Nov 2008 11:17 PM Originally Posted: 17 Nov 2008 10:46 PM
Thank you for the solution!!
I am getting the output, but with one after the other. I want one result on one line. How to make use of next line and carriage return character in the result to get the desired output??
Output Right now I am getting
XYZ has phone 123-234-2232 PQR has phone 332-334-5555
Desired output
XYZ has phone 123-432-2232
PQR has phone 332-334-5555