Return-Path: X-Original-To: apmail-poi-dev-archive@www.apache.org Delivered-To: apmail-poi-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DE6D1D895 for ; Thu, 30 Aug 2012 13:40:33 +0000 (UTC) Received: (qmail 63166 invoked by uid 500); 30 Aug 2012 13:40:33 -0000 Delivered-To: apmail-poi-dev-archive@poi.apache.org Received: (qmail 63110 invoked by uid 500); 30 Aug 2012 13:40:33 -0000 Mailing-List: contact dev-help@poi.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "POI Developers List" Delivered-To: mailing list dev@poi.apache.org Received: (qmail 63102 invoked by uid 99); 30 Aug 2012 13:40:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Aug 2012 13:40:33 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.115] (HELO eir.zones.apache.org) (140.211.11.115) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Aug 2012 13:40:32 +0000 Received: by eir.zones.apache.org (Postfix, from userid 80) id 795D4728D; Thu, 30 Aug 2012 13:40:12 +0000 (UTC) From: bugzilla@apache.org To: dev@poi.apache.org Subject: [Bug 53729] Shift rows wrongly updates static reference Date: Thu, 30 Aug 2012 13:40:12 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: POI X-Bugzilla-Component: XSSF X-Bugzilla-Keywords: X-Bugzilla-Severity: critical X-Bugzilla-Who: twapache@online.de X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: dev@poi.apache.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://issues.apache.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org https://issues.apache.org/bugzilla/show_bug.cgi?id=53729 --- Comment #3 from Thies Wellpott --- Created attachment 29307 --> https://issues.apache.org/bugzilla/attachment.cgi?id=29307&action=edit Proposed bug fix I think the bug can be fixed by changing org.apache.poi.ss.formula.FormulaShifter to check for absolute references. The attached patch does exactly this (it bases on the poi trunk but the source file did not change since poi 3.8). I only did a quick check with my own test case, it works. I did NOT test the modifications to AreaRef. A POI expert for this stuff should have a closer look. Also TODO is a recalculation of the formula because the base data has changed (is shifted!). Current solution is to call workbook.setForceFormulaRecalculation(true); manually when you use shiftRows() and are not sure about absolute references. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org For additional commands, e-mail: dev-help@poi.apache.org