Return-Path: X-Original-To: apmail-jackrabbit-users-archive@minotaur.apache.org Delivered-To: apmail-jackrabbit-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8D29A8ED3 for ; Thu, 18 Aug 2011 08:44:23 +0000 (UTC) Received: (qmail 24527 invoked by uid 500); 18 Aug 2011 08:44:22 -0000 Delivered-To: apmail-jackrabbit-users-archive@jackrabbit.apache.org Received: (qmail 23596 invoked by uid 500); 18 Aug 2011 08:44:15 -0000 Mailing-List: contact users-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@jackrabbit.apache.org Delivered-To: mailing list users@jackrabbit.apache.org Delivered-To: moderator for users@jackrabbit.apache.org Received: (qmail 46642 invoked by uid 99); 18 Aug 2011 06:26:20 -0000 X-ASF-Spam-Status: No, hits=4.2 required=5.0 tests=HTML_MESSAGE,SPF_NEUTRAL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Date: Wed, 17 Aug 2011 23:25:50 -0700 (PDT) From: proloyganguly To: users@jackrabbit.apache.org Message-ID: <1313648750493-3751877.post@n4.nabble.com> Subject: Problem with Document movement within folders MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_14141_18432542.1313648750494" X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_14141_18432542.1313648750494 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit javax.jcr.version.VersionException: /Documents/F2/BC: cannot move a target to a checked-in node This exception is coming after checkout the target folder. Please see the code below. Code: Session session = CustomSession.getSession(); Node node2 = session.getRootNode().getNode(path); node2.checkout(); // Destination folder Node node1 = session.getRootNode().getNode(docPath+"/"+ docName); node1.getParent().checkout();//Parent of source node2.checkout(); node1.getSession().move(node1.getPath() ,node2.getPath()); node2.getSession().save(); node1.getParent().checkin(); node2.checkin(); -- View this message in context: http://jackrabbit.510166.n4.nabble.com/Problem-with-Document-movement-within-folders-tp3751877p3751877.html Sent from the Jackrabbit - Users mailing list archive at Nabble.com. ------=_Part_14141_18432542.1313648750494--