Thanks for your prompt reply. It is very helpful.

On 6 February 2015 at 18:25, Christian Grün <christian.gruen@gmail.com> wrote:
PS: For more information, please read JavaDoc [1]. It tells: "Returns
the specified item, or an arbitrary item if the index is invalid. This
method needs to be implemented - and should only be called - if {@link
Iter#size()} returns the correct number of results."

[1] https://github.com/BaseXdb/basex/blob/master/basex-core/src/main/java/org/basex/query/iter/Iter.java



On Fri, Feb 6, 2015 at 1:53 PM, Christian Grün
<christian.gruen@gmail.com> wrote:
>>  Iter itr=pr.iter();
>>  Now, executing itr.get(0)  gives me "null"
>
> pr.iter().next(); should work.