-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Christian Grün wrote:
>> This was the missing link for moving a script from exist-db to 
>> BaseX. A more complete example in the docs would be helpful here.
> 
> To get a better understanding, could you give me a small example how 
> eXist converts XML to JSON, or a link to their documentation? Does
> it also support %output:method('json')?

This is the script that serializes to (XML), JSON and HTML in existdb

https://gist.github.com/zopyx/eee05f7a421a6c0b6b80

I can not recall where I found my primary source for RESTXQ scripts
in exist but there are some of their demos

https://github.com/eXist-db/demo-apps/blob/master/examples/xforms/restxq-demo.xql

http://exist-db.org/exist/apps/doc/xquery.xml#serialization

My broader goal is to figure out how to write scripts for both
databases in a compatible way in order to keep the necessary
changes as minimal as possible.

Andreas
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQGUBAEBAgAGBQJU5K3aAAoJEADcfz7u4AZjnA0LwIZMAohm1Q4A2HLIqvr6Ikis
Mvlz03RGIoNpfmUqruXgTK+MDK7nVR6S15GZ0WkUBAh8gT40PxUBjX861N9oHUs+
7UN79Rcmhw4uT9jPv47vT2Of6vx/WgE4KVpxMCevVICDuONsqQoM73CwZBmu9LqL
sbsNpx3vf1sG/QOvi1c6C28fJwKNIyvyQnj3Rc3TUUnQ4ZrstFXXVbTrWvO31Cvm
ND+0PjXg49u+63K5JkHtLyOM2kZQ4yDIGYuOAlhtxfTMaappILcuc/pN1UxjmRjj
7hMPTXC2EK/vEEvcYcCQiL3mZEAOpoGWibiElWfpQHHUsLPfxjQ7U0cqa5au+rT/
74Op+rrYPkKoAXtgPZeCdlyUjTr6qpZBGzyDyPww1xELb5tz74tMbm1uZdtJD3HZ
qZH7L72ZDJF10XOtXMgSv+BUwqjSdqG5tyYGzAXRqTSw6t3n2wus4MciKQonBU1S
R9s279cgXjAuS08Re5CuIXdKIIvFDYc=
=o8Ff
-----END PGP SIGNATURE-----

Reply via email to