Bug 57184

Summary: Missing Formula support for External References
Product: POI Reporter: Nick Burch <apache>
Component: SS CommonAssignee: POI Developers List <dev>
Status: NEW ---    
Severity: enhancement    
Priority: P2    
Version: 3.11-dev   
Target Milestone: ---   
Hardware: PC   
OS: Linux   

Description Nick Burch 2014-11-04 16:15:49 UTC
We now have some support for External References (Workbook + Name or Workbook + Sheet + Cell) in the formula parser. This bug is to track what work is still required for a full(ish) implementation:

 * When evaluating XSSF external references, the last seen values can be cached in the link table. These should be used when evaluating formulas, if the external workbook wasn't attached to the evaluation context. See #56752
 * When fetching the formula string in HSSF, the workbook name or id should be included in the string for external references. (XSSF returns the id)
 * There should be an easy way to get the XSSF external workbook ID replaced with the filename, for XSSF formulas with external references, to give a "what excel shows" form of the formula string
 * It should be possible to create HSSF formulas which refer to a new external workbook, with the link table being set up for it (failing, commented out unit test available)
 * It should be possible to create XSSF formulas which refer to a new external workbook, with the link table and relations being set up for it (failing, commented out unit test available)
Comment 1 IgnacioHR 2016-10-10 16:32:02 UTC
https://bz.apache.org/bugzilla/show_bug.cgi?id=60219

Patch contains implementation of requirement:

 * It should be possible to create HSSF formulas which refer to a new external workbook, with the link table being set up for it (failing, commented out unit test available)
Comment 2 Dominik Stadler 2017-01-08 20:24:47 UTC
The following unit-tests at https://github.com/ZuInnoTe/hadoopoffice.git can be incorporated to verify some of the things discussed in this enhancement:

* fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapred/OfficeFormatHadoopExcelTest.java
* fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapreduce/OfficeFormatHadoopExcelTest.java
Comment 3 PJ Fanning 2021-09-29 15:46:57 UTC
see https://github.com/apache/poi/pull/254