rug-compling / alpinocorpus

Library for handling Alpino corpora
GNU Lesser General Public License v2.1
8 stars 1 forks source link

xquery branch does not yet work on OS X #3

Closed jelmervdl closed 13 years ago

jelmervdl commented 13 years ago

It throws an exception as soon as I call CorpusReader::query(XPATH, "//node[@rel='su']"). alpino2db also does not work:

% ./alpino2db "//node[@rel='su']" ~/Workspace/treebanks/cdb.dact /tmp/su.dact
./alpino2db: Error: Cannot resolve container: .  Container not open and auto-open is not enabled.  Container may not exist.

edit: it could be related to this: http://forums.oracle.com/forums/thread.jspa?messageID=2189426

larsmans commented 13 years ago

I was afraid this might happen; DbCorpusReader uses some heuristics to work around the poorly documented (and apparently non-standard, or at least unforgiving) XQuery format used in DB XML, as well as the character encoding conventions that Qt forces upon us (and which differ from DB XML). I did not test these very thoroughly.

See the setNameAndCollection and runQuery member functions in src/DbCorpusReader.cpp.

jelmervdl commented 13 years ago

"Fixed" this in 167b02080863921cfaf987be18d214652d6a7192 by using an alias.