Ying Zhang wrote:
Hello Sagarjauhari,
On Feb 23, 2011, at 17:19 , sagarjauhari wrote:
>
> Hello, my xquery results are displaying only in a single line. The hello
> world example on http://monetdb.cwi.nl/XQuery/QuickTour/DOCMGT/ displays
> result correctly as:
>> doc("HelloWorld.xml")
>
>
>
> Hi
> Hello
> World
> Amsterdam
>
In the "Helloworld.xml" document, there is a text node between the nodes , and , which contains newline and white spaces.
The result of doc("HelloWorld.xml") includes these text nodes.
> But this:
> xquery>for $a in (1 to 3) return {$a}
> outputs this:
> 123
>
> and for the file :test.xq:
> (1, 42.0, "Hello World", test)
>
> the xquery
> mclient -lx -f xml test.xq
> outputs
>
> 1 42.000000 Hello World attr="value">test
So, this result is correct. If you want to print each node on a separate line, you need to explicitly add text nodes containing newlines (or maybe use another output format).
Hope this helps a bit.
Kind regards,
Jennie
>
> Any suggestions?
>
> Thanks in advance
> --
> View this message in context: http://old.nabble.com/monetdb-on-ubuntu-10.10---xquery-results-displaying-only-in-single-line%21-tp30996225p30996225.html
> Sent from the monetdb-users mailing list archive at Nabble.com.
>
>
> ------------------------------------------------------------------------------
> Free Software Download: Index, Search & Analyze Logs and other IT data in
> Real-Time with Splunk. Collect, index and harness all the fast moving IT data
> generated by your applications, servers and devices whether physical, virtual
> or in the cloud. Deliver compliance at lower cost and gain new business
> insights. http://p.sf.net/sfu/splunk-dev2dev
> _______________________________________________
> MonetDB-users mailing list
> MonetDB-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in
Real-Time with Splunk. Collect, index and harness all the fast moving IT data
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business
insights. http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
MonetDB-users mailing list
MonetDB-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/monetdb-users