Christian: option#2 is great, hope it find its way in the standard (add my vote to it) best *P
On 7/3/12 10:24 PM, Christian Grün wrote:
Hi Pascal,
you can either create a new, single string via the fn:string-join() function…
string-join(for $i in 1 to 10 return "x"," ")
…or use the "output:separator" option of BaseX:
declare option output:separator '\n'; (1 to 10) ! "x"
The second option, or a variation of it, may eventually find entrance into the official W3 XQuery Serialization Specification (see [1] for future details).
Hope this helps, Christian
[1] https://www.w3.org/Bugs/Public/show_bug.cgi?id=16311
Anyone has a little xquery / basex tip in getting rid of the extra white space that shows up at the beginning of each line after the first in the following xquery for $i in 1 to 10 return concat("x"," ") which in the UI returns x x x x x Just need a text output going to csv but this extra space is causing me headaches. tks *P
BaseX-Talk mailing list BaseX-Talk@mailman.uni-konstanz.de https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk