(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
Thanks,
Liam
Hi Liam, be sure I'll have a look at this tomorrow. Christian Am 12.12.2012 20:48 schrieb "Liam R E Quin" liam@w3.org:
(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
Thanks,
Liam
-- Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/ Pictures from old books: http://fromoldbooks.org/ (fromoldbooks.org uses BaseX e.g. for Search and for the tag cloud)
BaseX-Talk mailing list BaseX-Talk@mailman.uni-konstanz.de https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk
Hi Liam,
(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
The quoted readme.txt file is currently found in the parent directory, which lists all other client APIs [1]. As the latest version of this file also contains a link to our Wiki, I have removed to simply remove all the readme.txt comments. Instead, our Wiki page is supposed to include all relevant information for using the language bindings [2].
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
In Perl, the error message can be retrieved by enclosing the query with eval {...} and printing $@ if an error occurs. This is eg shown in Example.pl. If this does not help, you are invited to send us an example that demonstrates what goes wrong.
Christian
[1] https://github.com/BaseXdb/basex-api/tree/master/src/main [2] http://docs.basex.org/wiki/Clients [3] https://github.com/BaseXdb/basex-api/blob/master/src/main/perl/Example.pl
On Thu, 2012-12-13 at 18:30 +0100, Christian Grün wrote:
Hi Liam,
(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
The quoted readme.txt file is currently found in the parent directory, which lists all other client APIs [1].
Thank you, this led me to http://docs.basex.org/wiki/Server_Protocol which at least gave a list of methods and what they are expected to do.
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
In Perl, the error message can be retrieved by enclosing the query with eval {...} and printing $@ if an error occurs. This is eg shown in Example.pl. If this does not help, you are invited to send us an example that demonstrates what goes wrong.
Enclosed. When I run this the error I get is always: Database 'rdf' was opened in 0.6 ms.
If I use the commandline BsaeX program on the same query I get this instead (for this same deliberately malformed query): $ ~/packages/basex/BaseX7.3/bin/basexclient Username: admin Password: BaseX 7.3 [Client] Try help to get more information.
open rdf
Database 'rdf' was opened in 0.65 ms.
run /home/liam/tmp/error.xq
Stopped at line 1, column 9 in /home/liam/tmp/error.xq: [XPST0003] Unexpected end of query: 'with syntax err...'.
Liam
Liam,
the bug has been fixed [1]; feel free to check out the latest version [2].
Thanks for sharing this, Christian
[1] https://github.com/BaseXdb/basex-api/commit/aaa17f4e408e4e86d0ff3a72a8261acf... [2] https://github.com/BaseXdb/basex-api/blob/master/src/main/perl/BaseXClient.p...
______________________________________________
On Thu, Dec 13, 2012 at 8:29 PM, Liam R E Quin liam@w3.org wrote:
On Thu, 2012-12-13 at 18:30 +0100, Christian Grün wrote:
Hi Liam,
(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
The quoted readme.txt file is currently found in the parent directory, which lists all other client APIs [1].
Thank you, this led me to http://docs.basex.org/wiki/Server_Protocol which at least gave a list of methods and what they are expected to do.
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
In Perl, the error message can be retrieved by enclosing the query with eval {...} and printing $@ if an error occurs. This is eg shown in Example.pl. If this does not help, you are invited to send us an example that demonstrates what goes wrong.
Enclosed. When I run this the error I get is always: Database 'rdf' was opened in 0.6 ms.
If I use the commandline BsaeX program on the same query I get this instead (for this same deliberately malformed query): $ ~/packages/basex/BaseX7.3/bin/basexclient Username: admin Password: BaseX 7.3 [Client] Try help to get more information.
open rdf
Database 'rdf' was opened in 0.65 ms.
run /home/liam/tmp/error.xq
Stopped at line 1, column 9 in /home/liam/tmp/error.xq: [XPST0003] Unexpected end of query: 'with syntax err...'.
Liam
-- Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/ Pictures from old books: http://fromoldbooks.org/ Ankh: irc.sorcery.net irc.gnome.org freenode/#xml Co-author, 5th edition of "Beginning XML", Wrox, 2012
..and a related note to everyone: I have fixed a similar bug in the Ruby API.
It has already been noted that some of the APIs, such as PHP or Python, don’t support the current iterative binding yet. If some of you are using one of those clients and if you are interested in finalizing the APIs, your contributions are welcome!
Christian ___________________________
On Thu, Dec 13, 2012 at 11:11 PM, Christian Grün christian.gruen@gmail.com wrote:
Liam,
the bug has been fixed [1]; feel free to check out the latest version [2].
Thanks for sharing this, Christian
[1] https://github.com/BaseXdb/basex-api/commit/aaa17f4e408e4e86d0ff3a72a8261acf... [2] https://github.com/BaseXdb/basex-api/blob/master/src/main/perl/BaseXClient.p...
On Thu, Dec 13, 2012 at 8:29 PM, Liam R E Quin liam@w3.org wrote:
On Thu, 2012-12-13 at 18:30 +0100, Christian Grün wrote:
Hi Liam,
(1) The sample perl files and the perl module implementing the API mention a readme file that explains the methods; does anyone know where one might find such a readme file? It might answer my other question...
The quoted readme.txt file is currently found in the parent directory, which lists all other client APIs [1].
Thank you, this led me to http://docs.basex.org/wiki/Server_Protocol which at least gave a list of methods and what they are expected to do.
(2) if there's an error in my query and I catch the exception, the message I get is about how many milliseconds the query took, not the actual error. I can enclose my Perl script, but I'm wondering if others have seen this?
In Perl, the error message can be retrieved by enclosing the query with eval {...} and printing $@ if an error occurs. This is eg shown in Example.pl. If this does not help, you are invited to send us an example that demonstrates what goes wrong.
Enclosed. When I run this the error I get is always: Database 'rdf' was opened in 0.6 ms.
If I use the commandline BsaeX program on the same query I get this instead (for this same deliberately malformed query): $ ~/packages/basex/BaseX7.3/bin/basexclient Username: admin Password: BaseX 7.3 [Client] Try help to get more information.
open rdf
Database 'rdf' was opened in 0.65 ms.
run /home/liam/tmp/error.xq
Stopped at line 1, column 9 in /home/liam/tmp/error.xq: [XPST0003] Unexpected end of query: 'with syntax err...'.
Liam
-- Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/ Pictures from old books: http://fromoldbooks.org/ Ankh: irc.sorcery.net irc.gnome.org freenode/#xml Co-author, 5th edition of "Beginning XML", Wrox, 2012
On Thu, 2012-12-13 at 23:11 +0100, Christian Grün wrote:
Liam,
the bug has been fixed [1]; feel free to check out the latest version [2].
Thank you! Confirmed as fixed.
Liam
basex-talk@mailman.uni-konstanz.de