Hello Djoerd,
Thanks for the feedback. One reason (that i can see) to do it from
stdin is so that compression can be used (without having to be aware
of it), for example:
bzcat collection.tar.bz2 | mclient -lxq -C collection
But I do agree with you that it would be useful to have an XQuery
function too, as not everyone is using the mclient interface.
Greetings,
Wouter
Oh yes, and i forgot cvs does not unify its diff by default... hereby
the unified diff for the clients package.
(sooner or later I will learn to do things right the first time :)
2009/8/27 Djoerd Hiemstra
Hi Wouter,
Sounds very useful to me! Why is it not simply changed in pf:add-doc(), or put in a new function pf:add-archive()?
Best, Djoerd.
Wouter Alink schreef:
Hello devs,
Roberto and I yesterday discussed that it would be useful to be able to load (compressed) XML collections directly into MonetDB/XQuery. The attached diff provides a new feature for loading multiple XML docs directly from tar files. Usage: "mclient -lxq -C <colname>" and pass a tarfile via stdin, see example below.
My question: is this useful enough to make it into MonetDB? And if so, is the current syntax appropriate. Comments are appreciated.
Greetings, Wouter
$ mkdir xmlfiles $ echo "<abc/>" > xmlfiles/aap.xml $ echo "<abc/>" > xmlfiles/beer.xml $ tar cf xmlfiles.tar xmlfiles $ mclient -lxq -C xmlfiles < xmlfiles.tar Copying TAR file into collection: 'xmlfiles' Name: xmlfiles/beer.xml Length: 7 Name: xmlfiles/aap.xml Length: 7 $ echo 'pf:documents("xmlfiles")' | mclient -lxq <document updatable="false" url="xmlfiles/aap.xml" collection="xmlfiles">xmlfiles/aap.xml</document>, <document updatable="false" url="xmlfiles/beer.xml" collection="xmlfiles">xmlfiles/beer.xml</document> $
------------------------------------------------------------------------
------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july ------------------------------------------------------------------------
_______________________________________________ Monetdb-developers mailing list Monetdb-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-developers