jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stephan lohwasser <stephan.lohwas...@systemone.at>
Subject session.move() error: ItemExistsException despite same name siblings
Date Mon, 12 Jun 2006 16:33:33 GMT
hello all,

i have a problem moving nodes:
i am trying to move one 'element' node from one 'page' to another 'page'.
elements are always stored below the pages 'element root node'.

the elements are same name siblings below the element root and support 
here is the nodetypes.xml excerpt:
<!-- element root definition -->
<nodeType hasOrderableChildNodes="true" isMixin="false" 
    <childNodeDefinition autoCreated="false" 
defaultPrimaryType="s1NT:element" mandatory="false"
                         name="s1:element" onParentVersion="COPY" 
protected="false" sameNameSiblings="true" hasOrderableChildNodes="true">

<!-- element definition -->
<nodeType hasOrderableChildNodes="true" isMixin="false" name="s1NT:element">

i do already have 3 same-name-siblings at the destination position:
18:15:05,047 INFO  [ElementFactoryImpl] 
18:15:05,047 INFO  [ElementFactoryImpl] 
18:15:05,047 INFO  [ElementFactoryImpl] 

when i call session.move(srcPath, destPath), with srcPath being: 
/s1:root/s1:pages/s1:page[4]/s1:elementRoot/s1:element and destPath 
being /s1:root/s1:pages/s1:page[3]/s1:elementRoot/s1:element,  trying to 
move the first element below page[4] to the end of the elments of 
page[3], i get the following logs:
18:15:05,047 INFO  [ElementFactoryImpl] moving 
/s1:root/s1:pages/s1:page[4]/s1:elementRoot/s1:element to 
18:15:05,047 ERROR [S1SessionImpl] javax.jcr.ItemExistsException: 

do i have any errors in my code or nodetypes xml? the javadocs say this 
happens if i do not have same name siblings, but this can hardly be the 
thanks a lot

View raw message