You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by Jörn Franke <jo...@gmail.com> on 2017/01/03 20:03:32 UTC

Re: Writing workbooks with linked workbooks using XSSFWorkbook

Hi,

sorry I was a little bit late. I tried with 82 and still the same error:

java.lang.RuntimeException: Not Implemented - see bug #57184


I do have a unit test, but it contains a lot of Hadoop stuff.
Basically this line fails with the message above:

currentWorkbook.linkExternalWorkbook(name,currentLinkedWorkbookParser.getCurrentWorkbook());


I can clearly see in the source code of XSSFWorkbook that
linkExternalWorkbook simply throws a runtime Exception.

The only thing that i want to do - and which works with the Excel2003
.xls format - is to add an external workbook to the current workbook,
refer in a formula to it, e.g. via [linkedwbfile.xlsx]Sheet1!B1. Even
if do not use linkExternalWorkbook, but only setupReferencedWorkbooks
then i get a null pointer exception when setting the formula referring
to an external workbook in the cell. Again this is only for
XSSFWorkbook when modifying/adding cells. HSSFWorkbook works fine.

I assume the formula evaluator of XSSFWorkbook simply does not
understand formulas with external workbook references.


Let me know if I can do further analysis to solve the issue.

thank you a lot.

Best regards


On Sat, Dec 31, 2016 at 6:00 PM, Dominik Stadler <do...@gmx.at>
wrote:

> Hi,
>
> Bug 60219 was not fixed yet, but it is now.
>
> Can you re-try with a recent build from trunk or use the binaries from
> https://builds.apache.org/view/POI/job/POI-DSL-1.6/65/ when it finishes.
>
> Thanks... Dominik.
>
> On Tue, Dec 27, 2016 at 5:21 PM, Jörn Franke <jo...@gmail.com> wrote:
>
> > There is already a bug report, see my message.
> >
> > > On 27 Dec 2016, at 17:15, Murphy, Mark <mu...@metalexmfg.com>
> > wrote:
> > >
> > > If you create an issue in bugzilla with a unit test, It will be easier
> > to get that fixed.
> > >
> > > -----Original Message-----
> > > From: Jörn Franke [mailto:jornfranke@gmail.com]
> > > Sent: Tuesday, December 27, 2016 9:53 AM
> > > To: user@poi.apache.org
> > > Subject: Writing workbooks with linked workbooks using XSSFWorkbook
> > >
> > > Dear all,
> > >
> > > I am currently writing an open source library for reading/writing
> office
> > files on Hadoop/Spark/Hive/etc. The code is on Github and an official
> > release in form of a library on maven central will follow soon.
> > > The Excel files will be supported by the Apache POI library (3.15).
> > > So far everything works quiet well, such as reading from linked
> > workbooks (HSSF & XSSF), writing workbooks with linked workbooks (HSSF).
> > However, I have some issues with writing workbooks with linked workbooks
> > using XSSF. I receive the following exception (when calling
> > linkexternalworkbooks):
> > >
> > > RuntimeException
> > > <http://grepcode.com/file/repository.grepcode.com/java/
> > root/jdk/openjdk/6-b27/java/lang/RuntimeException.java#RuntimeException
> > >("Not
> > > Implemented - see bug #57184");
> > >
> > >
> > > The bug (https://bz.apache.org/bugzilla/show_bug.cgi?id=57184) refers
> > to bug 60219, which is supposed to be fixed in 3.15. However, it does not
> > seem that this bug really solves the issue I have.
> > >
> > > Does anyone know when external workbooks for XSSFWorkbooks will be
> > supported?
> > >
> > >
> > > Thank you a lot.
> > >
> > >
> > > best regards
> > >  B‹KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
> KKKKKKKKCB•
> > È [œÝXœØÜšX™K  K[XZ[ ˆ \Ù\‹][œÝXœØÜšX™P  ÚK˜\ XÚ K›Ü™ÃB‘›Üˆ Y  ] [Û˜[
> > ÛÛ[X[™ Ë  K[XZ[ ˆ \Ù\‹Z [    ÚK˜\ XÚ K›Ü™ÃB
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
> > For additional commands, e-mail: user-help@poi.apache.org
> >
> >
>

Re: Writing workbooks with linked workbooks using XSSFWorkbook

Posted by Jörn Franke <jo...@gmail.com>.
Ok, thank you. I will see, but I cannot promise anything.

> On 8 Jan 2017, at 21:23, Dominik Stadler <do...@gmx.at> wrote:
> 
> Hi,
> 
> Unfortunately this is likely to stay unsupported until somebody comes up
> with the necessary changes. None of the few active devs is currently
> working on this as far as I see, though. Patches are always welcome if you
> managed to take a closer look yourself.
> 
> Dominik.
> 
>> On Tue, Jan 3, 2017 at 9:06 PM, Jörn Franke <jo...@gmail.com> wrote:
>> 
>> oh btw. you do not need a Hadoop installation to run the tests, they are
>> simple unit tests.
>> Simply clone https://github.com/ZuInnoTe/hadoopoffice.git
>> Remove all the @Ignore tags from
>> *
>> fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapred/
>> OfficeFormatHadoopExcelTest.java
>> * fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapreduce/
>> OfficeFormatHadoopExcelTest.java
>> 
>> Go to the fileformat. Run gradle clean build
>> 
>>> On Tue, Jan 3, 2017 at 9:03 PM, Jörn Franke <jo...@gmail.com> wrote:
>>> 
>>> Hi,
>>> 
>>> sorry I was a little bit late. I tried with 82 and still the same error:
>>> 
>>> java.lang.RuntimeException: Not Implemented - see bug #57184
>>> 
>>> 
>>> I do have a unit test, but it contains a lot of Hadoop stuff. Basically
>> this line fails with the message above:
>>> 
>>> currentWorkbook.linkExternalWorkbook(name,currentLinkedWorkbookParser.
>> getCurrentWorkbook());
>>> 
>>> 
>>> I can clearly see in the source code of XSSFWorkbook that
>> linkExternalWorkbook simply throws a runtime Exception.
>>> 
>>> The only thing that i want to do - and which works with the Excel2003
>> .xls format - is to add an external workbook to the current workbook, refer
>> in a formula to it, e.g. via [linkedwbfile.xlsx]Sheet1!B1. Even if do not
>> use linkExternalWorkbook, but only setupReferencedWorkbooks then i get a
>> null pointer exception when setting the formula referring to an external
>> workbook in the cell. Again this is only for XSSFWorkbook when
>> modifying/adding cells. HSSFWorkbook works fine.
>>> 
>>> I assume the formula evaluator of XSSFWorkbook simply does not
>> understand formulas with external workbook references.
>>> 
>>> 
>>> Let me know if I can do further analysis to solve the issue.
>>> 
>>> thank you a lot.
>>> 
>>> Best regards
>>> 
>>> 
>>> On Sat, Dec 31, 2016 at 6:00 PM, Dominik Stadler <dominik.stadler@gmx.at
>>> 
>>> wrote:
>>> 
>>>> Hi,
>>>> 
>>>> Bug 60219 was not fixed yet, but it is now.
>>>> 
>>>> Can you re-try with a recent build from trunk or use the binaries from
>>>> https://builds.apache.org/view/POI/job/POI-DSL-1.6/65/ when it
>> finishes.
>>>> 
>>>> Thanks... Dominik.
>>>> 
>>>> On Tue, Dec 27, 2016 at 5:21 PM, Jörn Franke <jo...@gmail.com>
>>>> wrote:
>>>> 
>>>>> There is already a bug report, see my message.
>>>>> 
>>>>>> On 27 Dec 2016, at 17:15, Murphy, Mark <mu...@metalexmfg.com>
>>>>> wrote:
>>>>>> 
>>>>>> If you create an issue in bugzilla with a unit test, It will be
>> easier
>>>>> to get that fixed.
>>>>>> 
>>>>>> -----Original Message-----
>>>>>> From: Jörn Franke [mailto:jornfranke@gmail.com]
>>>>>> Sent: Tuesday, December 27, 2016 9:53 AM
>>>>>> To: user@poi.apache.org
>>>>>> Subject: Writing workbooks with linked workbooks using XSSFWorkbook
>>>>>> 
>>>>>> Dear all,
>>>>>> 
>>>>>> I am currently writing an open source library for reading/writing
>>>> office
>>>>> files on Hadoop/Spark/Hive/etc. The code is on Github and an official
>>>>> release in form of a library on maven central will follow soon.
>>>>>> The Excel files will be supported by the Apache POI library (3.15).
>>>>>> So far everything works quiet well, such as reading from linked
>>>>> workbooks (HSSF & XSSF), writing workbooks with linked workbooks
>> (HSSF).
>>>>> However, I have some issues with writing workbooks with linked
>> workbooks
>>>>> using XSSF. I receive the following exception (when calling
>>>>> linkexternalworkbooks):
>>>>>> 
>>>>>> RuntimeException
>>>>>> <http://grepcode.com/file/repository.grepcode.com/java/
>>>>> root/jdk/openjdk/6-b27/java/lang/RuntimeException.java#
>> RuntimeException
>>>>>> ("Not
>>>>>> Implemented - see bug #57184");
>>>>>> 
>>>>>> 
>>>>>> The bug (https://bz.apache.org/bugzilla/show_bug.cgi?id=57184)
>> refers
>>>>> to bug 60219, which is supposed to be fixed in 3.15. However, it does
>>>> not
>>>>> seem that this bug really solves the issue I have.
>>>>>> 
>>>>>> Does anyone know when external workbooks for XSSFWorkbooks will be
>>>>> supported?
>>>>>> 
>>>>>> 
>>>>>> Thank you a lot.
>>>>>> 
>>>>>> 
>>>>>> best regards
>>>>>> B‹KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
>>>> KKKKKKKKKKCB•
>>>>> È [œÝXœØÜšX™K  K[XZ[ ˆ \Ù\‹][œÝXœØÜšX™P  ÚK˜\ XÚ K›Ü™ÃB‘›Üˆ Y  ] [Û˜[
>>>>> ÛÛ[X[™ Ë  K[XZ[ ˆ \Ù\‹Z [    ÚK˜\ XÚ K›Ü™ÃB
>>>>> 
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
>>>>> For additional commands, e-mail: user-help@poi.apache.org
>>>>> 
>>>>> 
>>>> 
>>> 
>>> 
>> 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org


Re: Writing workbooks with linked workbooks using XSSFWorkbook

Posted by Dominik Stadler <do...@gmx.at>.
Hi,

Unfortunately this is likely to stay unsupported until somebody comes up
with the necessary changes. None of the few active devs is currently
working on this as far as I see, though. Patches are always welcome if you
managed to take a closer look yourself.

Dominik.

On Tue, Jan 3, 2017 at 9:06 PM, Jörn Franke <jo...@gmail.com> wrote:

> oh btw. you do not need a Hadoop installation to run the tests, they are
> simple unit tests.
> Simply clone https://github.com/ZuInnoTe/hadoopoffice.git
> Remove all the @Ignore tags from
> *
> fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapred/
> OfficeFormatHadoopExcelTest.java
> * fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapreduce/
> OfficeFormatHadoopExcelTest.java
>
> Go to the fileformat. Run gradle clean build
>
> On Tue, Jan 3, 2017 at 9:03 PM, Jörn Franke <jo...@gmail.com> wrote:
>
> > Hi,
> >
> > sorry I was a little bit late. I tried with 82 and still the same error:
> >
> > java.lang.RuntimeException: Not Implemented - see bug #57184
> >
> >
> > I do have a unit test, but it contains a lot of Hadoop stuff. Basically
> this line fails with the message above:
> >
> > currentWorkbook.linkExternalWorkbook(name,currentLinkedWorkbookParser.
> getCurrentWorkbook());
> >
> >
> > I can clearly see in the source code of XSSFWorkbook that
> linkExternalWorkbook simply throws a runtime Exception.
> >
> > The only thing that i want to do - and which works with the Excel2003
> .xls format - is to add an external workbook to the current workbook, refer
> in a formula to it, e.g. via [linkedwbfile.xlsx]Sheet1!B1. Even if do not
> use linkExternalWorkbook, but only setupReferencedWorkbooks then i get a
> null pointer exception when setting the formula referring to an external
> workbook in the cell. Again this is only for XSSFWorkbook when
> modifying/adding cells. HSSFWorkbook works fine.
> >
> > I assume the formula evaluator of XSSFWorkbook simply does not
> understand formulas with external workbook references.
> >
> >
> > Let me know if I can do further analysis to solve the issue.
> >
> > thank you a lot.
> >
> > Best regards
> >
> >
> > On Sat, Dec 31, 2016 at 6:00 PM, Dominik Stadler <dominik.stadler@gmx.at
> >
> > wrote:
> >
> >> Hi,
> >>
> >> Bug 60219 was not fixed yet, but it is now.
> >>
> >> Can you re-try with a recent build from trunk or use the binaries from
> >> https://builds.apache.org/view/POI/job/POI-DSL-1.6/65/ when it
> finishes.
> >>
> >> Thanks... Dominik.
> >>
> >> On Tue, Dec 27, 2016 at 5:21 PM, Jörn Franke <jo...@gmail.com>
> >> wrote:
> >>
> >> > There is already a bug report, see my message.
> >> >
> >> > > On 27 Dec 2016, at 17:15, Murphy, Mark <mu...@metalexmfg.com>
> >> > wrote:
> >> > >
> >> > > If you create an issue in bugzilla with a unit test, It will be
> easier
> >> > to get that fixed.
> >> > >
> >> > > -----Original Message-----
> >> > > From: Jörn Franke [mailto:jornfranke@gmail.com]
> >> > > Sent: Tuesday, December 27, 2016 9:53 AM
> >> > > To: user@poi.apache.org
> >> > > Subject: Writing workbooks with linked workbooks using XSSFWorkbook
> >> > >
> >> > > Dear all,
> >> > >
> >> > > I am currently writing an open source library for reading/writing
> >> office
> >> > files on Hadoop/Spark/Hive/etc. The code is on Github and an official
> >> > release in form of a library on maven central will follow soon.
> >> > > The Excel files will be supported by the Apache POI library (3.15).
> >> > > So far everything works quiet well, such as reading from linked
> >> > workbooks (HSSF & XSSF), writing workbooks with linked workbooks
> (HSSF).
> >> > However, I have some issues with writing workbooks with linked
> workbooks
> >> > using XSSF. I receive the following exception (when calling
> >> > linkexternalworkbooks):
> >> > >
> >> > > RuntimeException
> >> > > <http://grepcode.com/file/repository.grepcode.com/java/
> >> > root/jdk/openjdk/6-b27/java/lang/RuntimeException.java#
> RuntimeException
> >> > >("Not
> >> > > Implemented - see bug #57184");
> >> > >
> >> > >
> >> > > The bug (https://bz.apache.org/bugzilla/show_bug.cgi?id=57184)
> refers
> >> > to bug 60219, which is supposed to be fixed in 3.15. However, it does
> >> not
> >> > seem that this bug really solves the issue I have.
> >> > >
> >> > > Does anyone know when external workbooks for XSSFWorkbooks will be
> >> > supported?
> >> > >
> >> > >
> >> > > Thank you a lot.
> >> > >
> >> > >
> >> > > best regards
> >> > >  B‹KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
> >> KKKKKKKKKKCB•
> >> > È [œÝXœØÜšX™K  K[XZ[ ˆ \Ù\‹][œÝXœØÜšX™P  ÚK˜\ XÚ K›Ü™ÃB‘›Üˆ Y  ] [Û˜[
> >> > ÛÛ[X[™ Ë  K[XZ[ ˆ \Ù\‹Z [    ÚK˜\ XÚ K›Ü™ÃB
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
> >> > For additional commands, e-mail: user-help@poi.apache.org
> >> >
> >> >
> >>
> >
> >
>

Re: Writing workbooks with linked workbooks using XSSFWorkbook

Posted by Jörn Franke <jo...@gmail.com>.
oh btw. you do not need a Hadoop installation to run the tests, they are
simple unit tests.
Simply clone https://github.com/ZuInnoTe/hadoopoffice.git
Remove all the @Ignore tags from
*
fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapred/OfficeFormatHadoopExcelTest.java
* fileformat/src/test/java/org/zuinnote/hadoop/office/format/mapreduce/OfficeFormatHadoopExcelTest.java

Go to the fileformat. Run gradle clean build

On Tue, Jan 3, 2017 at 9:03 PM, Jörn Franke <jo...@gmail.com> wrote:

> Hi,
>
> sorry I was a little bit late. I tried with 82 and still the same error:
>
> java.lang.RuntimeException: Not Implemented - see bug #57184
>
>
> I do have a unit test, but it contains a lot of Hadoop stuff. Basically this line fails with the message above:
>
> currentWorkbook.linkExternalWorkbook(name,currentLinkedWorkbookParser.getCurrentWorkbook());
>
>
> I can clearly see in the source code of XSSFWorkbook that linkExternalWorkbook simply throws a runtime Exception.
>
> The only thing that i want to do - and which works with the Excel2003 .xls format - is to add an external workbook to the current workbook, refer in a formula to it, e.g. via [linkedwbfile.xlsx]Sheet1!B1. Even if do not use linkExternalWorkbook, but only setupReferencedWorkbooks then i get a null pointer exception when setting the formula referring to an external workbook in the cell. Again this is only for XSSFWorkbook when modifying/adding cells. HSSFWorkbook works fine.
>
> I assume the formula evaluator of XSSFWorkbook simply does not understand formulas with external workbook references.
>
>
> Let me know if I can do further analysis to solve the issue.
>
> thank you a lot.
>
> Best regards
>
>
> On Sat, Dec 31, 2016 at 6:00 PM, Dominik Stadler <do...@gmx.at>
> wrote:
>
>> Hi,
>>
>> Bug 60219 was not fixed yet, but it is now.
>>
>> Can you re-try with a recent build from trunk or use the binaries from
>> https://builds.apache.org/view/POI/job/POI-DSL-1.6/65/ when it finishes.
>>
>> Thanks... Dominik.
>>
>> On Tue, Dec 27, 2016 at 5:21 PM, Jörn Franke <jo...@gmail.com>
>> wrote:
>>
>> > There is already a bug report, see my message.
>> >
>> > > On 27 Dec 2016, at 17:15, Murphy, Mark <mu...@metalexmfg.com>
>> > wrote:
>> > >
>> > > If you create an issue in bugzilla with a unit test, It will be easier
>> > to get that fixed.
>> > >
>> > > -----Original Message-----
>> > > From: Jörn Franke [mailto:jornfranke@gmail.com]
>> > > Sent: Tuesday, December 27, 2016 9:53 AM
>> > > To: user@poi.apache.org
>> > > Subject: Writing workbooks with linked workbooks using XSSFWorkbook
>> > >
>> > > Dear all,
>> > >
>> > > I am currently writing an open source library for reading/writing
>> office
>> > files on Hadoop/Spark/Hive/etc. The code is on Github and an official
>> > release in form of a library on maven central will follow soon.
>> > > The Excel files will be supported by the Apache POI library (3.15).
>> > > So far everything works quiet well, such as reading from linked
>> > workbooks (HSSF & XSSF), writing workbooks with linked workbooks (HSSF).
>> > However, I have some issues with writing workbooks with linked workbooks
>> > using XSSF. I receive the following exception (when calling
>> > linkexternalworkbooks):
>> > >
>> > > RuntimeException
>> > > <http://grepcode.com/file/repository.grepcode.com/java/
>> > root/jdk/openjdk/6-b27/java/lang/RuntimeException.java#RuntimeException
>> > >("Not
>> > > Implemented - see bug #57184");
>> > >
>> > >
>> > > The bug (https://bz.apache.org/bugzilla/show_bug.cgi?id=57184) refers
>> > to bug 60219, which is supposed to be fixed in 3.15. However, it does
>> not
>> > seem that this bug really solves the issue I have.
>> > >
>> > > Does anyone know when external workbooks for XSSFWorkbooks will be
>> > supported?
>> > >
>> > >
>> > > Thank you a lot.
>> > >
>> > >
>> > > best regards
>> > >  B‹KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
>> KKKKKKKKKKCB•
>> > È [œÝXœØÜšX™K  K[XZ[ ˆ \Ù\‹][œÝXœØÜšX™P  ÚK˜\ XÚ K›Ü™ÃB‘›Üˆ Y  ] [Û˜[
>> > ÛÛ[X[™ Ë  K[XZ[ ˆ \Ù\‹Z [    ÚK˜\ XÚ K›Ü™ÃB
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
>> > For additional commands, e-mail: user-help@poi.apache.org
>> >
>> >
>>
>
>