How to use Xpath to query elements loaded from different xml docs?
562355Feb 27 2007 — edited Apr 10 2007I have a big DBLP XML doc (95mb), to load into the container, i splitted the doc into many small xml docs by the publication types, such as articles, books, inproceedings, etc.
I tried to use xpath query such as
query 'collection()/dblp[article/author]/book[title]'
I got empty answers.
but if i use XQuery such as
query 'let $r:=collection()/dblp,$a :=$r/inproceedings/author
for $l2 in $r/book
where $a and $l2/title
return <result> {$l2}{$a}</result>'
i got answers. However, if i remove {$a} from the return clause, i still got empty answers.
is there any problem with my Xpath query and flwor Xquery?
regards,
xiaoying