Hi,

'retrieve' command works to retrieve binary resource which is stored in the database (with 'store' command).
if you add a document with 'add' command, you can access that document in your collection with 'position()' function.

eg:
$ ls raw-xml/
new.xml  test.xml
$ ls raw-binary/
BaseX_64px.png

$ basex -c "create db test raw-xml/test.xml" <-- create test database with initial document from test.xml

$ basex -c "open test; add raw-xml/new.xml" <-- add new.xml to test database

$ basex -c "open test; store raw-binary/BaseX_64px.png" <-- store BaseX_64px.png to test database

$ basex -q "db:open('test')[position() = 2]"
<new/>
$ basex -q "db:open('test')[position() = 1]"
<test/>

$ basex -c "open test; retrieve BaseX_64px.png"
�PNG

IDATx^�Z�gAMA��a
...

Hope it helps,
-andria



On Fri, Dec 13, 2013 at 4:37 AM, Kamineni, Rajeshwar <rajeshwar.kamineni@neustar.biz> wrote:
Hi

I have a document added using the ADD command.  How do I just view it without an XQUERY.

I thought RETRIEVE command should work but doesn’t help.

Are there any other ways??

Thanks

Raj Kamineni


_______________________________________________
BaseX-Talk mailing list
BaseX-Talk@mailman.uni-konstanz.de
https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk