jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ulrich <For...@gombers.de>
Subject Re: JCR-JQOM: JOIN returns Message: WARN NodeIteratorImpl - Exception retrieving Node with Id: null
Date Tue, 18 Jun 2013 06:32:59 GMT
Now I could create a SQL2 statement which delivers me the same result:

   "Select * from [nt:file] as parent " +
   "inner join [nt:resource] as child on ISCHILDNODE(child,parent) " +
   "WHERE ISDESCENDANTNODE(parent,[/content/testit])";

Do I have a logic problem here? I'm search the whole subtree of
"/content/testit" fo all nodes of type "nt:file" which have a child of type
"nt:resource".
The query should return me 4 nodes but instead it gives me four times the
message:
    "WARN  NodeIteratorImpl - Exception retrieving Node with Id: null"

Ulrich




> .. snip ..

>
> > Ulrich <Forums@gombers.de> hat am 17. Juni 2013 um 10:01 geschrieben:
> >
> >
> > Still fighting with JCR-JQOM:
> > I need to retrieve "jcr:lastModified" from jcr:contend-childnode of every
> > nt:file-Node. My approach is:
> >
> > Selector ntFileSelector = qomf.selector("nt:file", "Parent");
> > Selector jcrContentSelector = qomf.selector("nt:resource", "Child");
> > Join join = qomf.join(ntFileSelector, jcrContentSelector,
> > QueryObjectModelFactory.JCR_JOIN_TYPE_INNER,
> >      qomf.childNodeJoinCondition(jcrContentSelector.getSelectorName(),
> > ntFileSelector.getSelectorName()));
> > Constraint getSubtree =
> > qomf.descendantNode(ntFileSelector.getSelectorName(),
> > subtree);
> > QueryObjectModel qom = qomf.createQuery(join, getSubtree, null, null);
> > QueryResult queryResult = qom.execute();
> > nodeIterator = queryResult.getNodes();
> >
> > From this I get four times the message:
> >    WARN  NodeIteratorImpl - Exception retrieving Node with Id: null
> > This means I get this message for every node which I expected to be selected
> > within the subtree.
> >
> > If I run the query without the "JOIN":
> > QueryObjectModel qom = qomf.createQuery(ntFileSelector, getSubtree, null,
> > null);
> > it is fine.
> >
> > brdgs,
> > Ulrich

Mime
View raw message