Commit Graph

50 Commits

Author SHA1 Message Date
Javen O'Neal 726fe10074 bug 60260: parse unicode sheet names
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1778418 13f79535-47bb-0310-9956-ffa450edef68
2017-01-12 10:39:26 +00:00
Dominik Stadler 102c0d2173 Bug 60219: FormulaParser can't parse external references when sheet name is quoted
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1776796 13f79535-47bb-0310-9956-ffa450edef68
2016-12-31 16:53:16 +00:00
Javen O'Neal 8df4c77647 bug 59790: convert FormulaType class to enum
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1751210 13f79535-47bb-0310-9956-ffa450edef68
2016-07-04 05:37:06 +00:00
Javen O'Neal 79ebd4915d findbugs: SBSC_USE_STRINGBUFFER_CONCATENATION FormulaParser.parseAsColumnQuantifier() concatenates strings using + in a loop
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1747685 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 11:16:16 +00:00
Nick Burch 1197db5415 Javadoc fixes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1747674 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 09:42:09 +00:00
Nick Burch 937519fad5 Javadoc fixes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1747673 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 09:40:26 +00:00
Javen O'Neal 954d5f8be4 bug 57840: add structured reference formula parsing tests from FormulaParser.parseStructuredReference
git-svn-id: https://svn.apache.org/repos/asf/poi/branches/xssf_structured_references@1747655 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 07:33:30 +00:00
Javen O'Neal 068bb510be bug 57840: add javadocs (warn about stale XSSFTable cache), remove rowIndex argument from calls to FormulaParser.parse(String, FormulaParsingWorkbook, FormulaType, int sheetIndex) when rowIndex is irrelevant, clear xmlColumnPr and commonXPath during updateHeaders so that users have a mechanism to clear invalidated cached values
git-svn-id: https://svn.apache.org/repos/asf/poi/branches/xssf_structured_references@1747627 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 04:20:41 +00:00
Javen O'Neal b983f435d1 whitespace (tabs to spaces)
git-svn-id: https://svn.apache.org/repos/asf/poi/branches/xssf_structured_references@1747622 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 01:57:13 +00:00
Javen O'Neal 83abda843a bug 57840: apply patch from Daniel Livshen and Greg Woolsey to get structured references working in XSSFWorkbook formulas
git-svn-id: https://svn.apache.org/repos/asf/poi/branches/xssf_structured_references@1747612 13f79535-47bb-0310-9956-ffa450edef68
2016-06-10 00:21:59 +00:00
Andreas Beeker dde2a25283 #59170 - Remove deprecated classes (POI 3.15) - use FormulaError instead of ErrorConstants
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1744000 13f79535-47bb-0310-9956-ffa450edef68
2016-05-16 09:38:42 +00:00
Dominik Stadler b9e7c32ffe Bug 58648: Fix handling whitespaces in formulas, unfortunately blank can be the intersection operator as well, so we need to try and skip it as whitespace if intersection fails which can lead to hard to track bugs or misleading error messages with some formulas
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1738033 13f79535-47bb-0310-9956-ffa450edef68
2016-04-06 19:50:08 +00:00
Andreas Beeker 07dc2b9e08 findbugs fixes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1715087 13f79535-47bb-0310-9956-ffa450edef68
2015-11-19 01:44:38 +00:00
Javen O'Neal 1aa81eb463 bug58452: set cell formulas containing unregistered function names
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1711605 13f79535-47bb-0310-9956-ffa450edef68
2015-10-31 11:57:39 +00:00
Nick Burch aa455c91fd Fix some Forbidden APIs errors
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1700670 13f79535-47bb-0310-9956-ffa450edef68
2015-09-01 21:09:20 +00:00
David North 5706c2ac9b Make intersection formulae work in XSSF. Patch from Matt Hillsdon plus additional tests.
https://bz.apache.org/bugzilla/show_bug.cgi?id=52111

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1696549 13f79535-47bb-0310-9956-ffa450edef68
2015-08-19 10:10:08 +00:00
David North 16a9eca7c8 My own patch to fix #56328
Add tests for initial patch applied by Nick in r1582892

Fix and test AreaReference#isWholeColumnReference to take account of the prevailing spreadsheet version. Fixing all users of this is a big undertaking, so for now I've left a fallback on the original behaviour for some cases.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1685101 13f79535-47bb-0310-9956-ffa450edef68
2015-06-12 15:20:10 +00:00
Dominik Stadler 7c9d23d887 Remove unused local variable
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1648159 13f79535-47bb-0310-9956-ffa450edef68
2014-12-28 09:09:11 +00:00
Nick Burch 1161077a6b More progress towards #55906 - FormulaParser is able to identify and parse multi-sheet references, but not yet fully round-trip them. (No evaluation support yet either)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1613317 13f79535-47bb-0310-9956-ffa450edef68
2014-07-24 22:44:51 +00:00
Nick Burch ed7140b3d8 Move towards supporting same workbook named ranges in external style for xssf
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611961 13f79535-47bb-0310-9956-ffa450edef68
2014-07-19 20:51:23 +00:00
Nick Burch 58096a6862 Start to add XSSF specific handling for NameX (named ranges or functions from another file) #56737
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611958 13f79535-47bb-0310-9956-ffa450edef68
2014-07-19 20:30:31 +00:00
Nick Burch 7c382f9f37 The way that HSSF and XSSF stores references to external sheets are rather different, so begin to reflect that in how we parse their formulas into Ptgs
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611906 13f79535-47bb-0310-9956-ffa450edef68
2014-07-19 12:49:41 +00:00
Nick Burch 4c362590d8 Start to support formula parsing of sheet-specified named ranges, required for a full fix to bug #56737
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611753 13f79535-47bb-0310-9956-ffa450edef68
2014-07-18 18:30:16 +00:00
Nick Burch f52fe377ae Patch from bug #56328 from David North - the maximum row number in a formula depends on HSSF vs XSSF
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1582892 13f79535-47bb-0310-9956-ffa450edef68
2014-03-28 21:54:30 +00:00
Nick Burch 3400cf0d44 Patch from Marcel May from bug #51875 - More XSSF formula new-line support
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1210299 13f79535-47bb-0310-9956-ffa450edef68
2011-12-05 00:52:39 +00:00
Yegor Kozlov 82aa0c6f09 moved ptg classes to org.apache.poi.ss.formula.ptg
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1038688 13f79535-47bb-0310-9956-ffa450edef68
2010-11-24 16:50:47 +00:00
Yegor Kozlov e994534f3e moved common formula-related code to org.apache.poi.ss.formula, eliminated dependencies on HSSF, reduced the number of eclipse warnings
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1037439 13f79535-47bb-0310-9956-ffa450edef68
2010-11-21 12:09:29 +00:00
Yegor Kozlov 5df572a3b6 fixed evaluation of XSSF workbooks containing formulas with reference errors (#REF!), see Bugzilla 49783
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@989100 13f79535-47bb-0310-9956-ffa450edef68
2010-08-25 13:29:55 +00:00
Yegor Kozlov 8f4aff0e1a fixed FormulaParser to correctly process defined names with underscore, see bugzilla 49725
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@984823 13f79535-47bb-0310-9956-ffa450edef68
2010-08-12 15:10:12 +00:00
Yegor Kozlov de13c1193c Fixed parsing formulas containing defined names beginning with an underscore, see Bug 9640
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@979329 13f79535-47bb-0310-9956-ffa450edef68
2010-07-26 15:52:57 +00:00
Josh Micich 5c3fcf7a3c Fixed FormulaParser to allow negative elements in array literals.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@893898 13f79535-47bb-0310-9956-ffa450edef68
2009-12-25 23:26:47 +00:00
Josh Micich 37790e51e4 Some more clean up of array formula support in preparation for patch 48292
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@888577 13f79535-47bb-0310-9956-ffa450edef68
2009-12-08 21:30:35 +00:00
Josh Micich 1992068d14 Controlled instantiation of BoolPtg (made consistent with ErrPtg)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@887477 13f79535-47bb-0310-9956-ffa450edef68
2009-12-05 01:04:44 +00:00
Josh Micich e55e9044aa Made POI follow the rules for encoding unary +/- operators more closely.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@887028 13f79535-47bb-0310-9956-ffa450edef68
2009-12-04 01:25:34 +00:00
Josh Micich 5c7dbb2730 Patch 48284 - raise visibility of FormulaParseException
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@885007 13f79535-47bb-0310-9956-ffa450edef68
2009-11-27 21:01:59 +00:00
Josh Micich 00e64461a9 Made AbstractFunctionPtg immutable, other minor improvements
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@836101 13f79535-47bb-0310-9956-ffa450edef68
2009-11-14 02:41:24 +00:00
Josh Micich b7d7f53ea6 rolling back r781622
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@781623 13f79535-47bb-0310-9956-ffa450edef68
2009-06-04 00:06:31 +00:00
Josh Micich f7148c9431 Fix for javadoc error in Cell.setCellValue(Date) found by Mike Curwen
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@781622 13f79535-47bb-0310-9956-ffa450edef68
2009-06-03 23:57:31 +00:00
Yegor Kozlov c444cd27e9 Allow columns greater than 255 and rows greater than 0x100000 in XSSF formulas
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@775701 13f79535-47bb-0310-9956-ffa450edef68
2009-05-17 16:35:25 +00:00
Josh Micich 2b1d0dd9ab encapsulated hasUnlimitedVarags() logic into FunctionMetadata
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@775575 13f79535-47bb-0310-9956-ffa450edef68
2009-05-17 02:02:48 +00:00
Yegor Kozlov 62b0595b83 Allow 255 arguments for excel functions in XSSF, see bugzilla 46279
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@766251 13f79535-47bb-0310-9956-ffa450edef68
2009-04-18 07:12:38 +00:00
Josh Micich 527b4c7fc5 Bug 46951 - fixed formula parser to better handle range operators and whole row/column refs.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@762250 13f79535-47bb-0310-9956-ffa450edef68
2009-04-06 08:22:25 +00:00
Yegor Kozlov 5d5f76be67 Fixed formula parser to handle names with backslashes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@744749 13f79535-47bb-0310-9956-ffa450edef68
2009-02-15 20:45:24 +00:00
Josh Micich 011fafc7ae Modified formula parser to encode SUM taking a single argument as tAttrSum (from comment 7 of bugzilla 46643)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@740159 13f79535-47bb-0310-9956-ffa450edef68
2009-02-02 23:53:22 +00:00
Josh Micich e3775b8b1d Fix for bug 46643 - formula parser should encode range operator with tMemFunc
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@740146 13f79535-47bb-0310-9956-ffa450edef68
2009-02-02 23:10:30 +00:00
Yegor Kozlov 177533e23b fixed formula parser to correctly resolve sheet-level names
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@729028 13f79535-47bb-0310-9956-ffa450edef68
2008-12-23 16:19:07 +00:00
Josh Micich bff86351a1 more generics compiler warnings fixes for poi.ss.formula
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@723104 13f79535-47bb-0310-9956-ffa450edef68
2008-12-03 22:34:26 +00:00
Josh Micich 6f28f85004 Initial support for union operator in FormulaParser (fix for broken junits)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@718838 13f79535-47bb-0310-9956-ffa450edef68
2008-11-19 02:01:58 +00:00
Josh Micich 96cb7321ba Merged revisions 699178,699487,699489,699761 via svnmerge from
https://svn.apache.org/repos/asf/poi/trunk

........
  r699178 | josh | 2008-09-25 21:49:20 -0700 (Thu, 25 Sep 2008) | 1 line
  
  Changed HSSFEvaluationWorkbook to avoid re-parsing cell formulas during execution. (working towards fix for bug 45865)
........
  r699487 | josh | 2008-09-26 13:25:45 -0700 (Fri, 26 Sep 2008) | 1 line
  
  Fix formula parser to properly support the range operator. Small fixes to parsing of sheet names and full column references.
........
  r699489 | josh | 2008-09-26 13:32:06 -0700 (Fri, 26 Sep 2008) | 1 line
  
  Code cleanup in junit
........
  r699761 | josh | 2008-09-27 19:04:31 -0700 (Sat, 27 Sep 2008) | 1 line
  
  Bug 45865 - modified Formula Parser/Evaluator to handle cross-worksheet formulas
........


git-svn-id: https://svn.apache.org/repos/asf/poi/branches/ooxml@700234 13f79535-47bb-0310-9956-ffa450edef68
2008-09-29 20:09:09 +00:00
Josh Micich e188e7737d Merged revisions 696860,696898 via svnmerge from
https://svn.apache.org/repos/asf/poi/trunk

Quite a lot of manual fixing required. Also moved CellValue to top level class.  
........
  r696860 | josh | 2008-09-18 17:02:21 -0700 (Thu, 18 Sep 2008) | 1 line
  
  code clean-up (removed compiler warnings/unused methods)
........
  r696898 | josh | 2008-09-18 19:19:58 -0700 (Thu, 18 Sep 2008) | 1 line
  
  Partitioning common formula logic.  Introduced FormulaParsingWorkbook and EvaluationWorkbook interfaces to make merge with ooxml branch easier
........


git-svn-id: https://svn.apache.org/repos/asf/poi/branches/ooxml@696961 13f79535-47bb-0310-9956-ffa450edef68
2008-09-19 07:32:34 +00:00