Jump to content
  • Apparently empty cells aren't empty, only after a non-empty cell

    Assigned User shertage
    CategoryBug report
    Component: 32401
    ResolutionUnable to Reproduce

    We produce an Excel report with Jasper. One column is defined to be a text field with:


    * Expression: $F{closingDate}

    * Evaluation Time: Now

    * Blank When NULL

    * Strech With Overflow

    * Pattern "dd.MM.yyyy"


    In the model, the 'closingDate' is of type 'java.util.Date' and some values are NULL.


    If you look at the attached file, you'll see something pretty interesting: Apparently empty cells aren't empty until there has been an non-empty cell. This causes formulas to no longer work, as you can't detect whether a cell is empty or not. As it's seen as non-empty, excel tries (and fails) to use that "empty" value for calculations.


    Investigating the underlying XML reveals, that the non-empty empty cells contain a reference to a shared string like so:



    which is defined as:


    Whereas truly empty cells have no tag at all, or (you can test this manually) an empty tag (so no shared string reference).



    Is there anything that I can do about it or is it truly a bug in Jasper?

    Attachments: jasper-bug.xlsx

    User Feedback

    Recommended Comments


    We couldn't reproduce this bug locally. See the attached JRXML file that can be run using a JREmptyDatasource with multiple records.

    If possible, please post your JRXML sample file.

    Thank you,


    Link to comment
    Share on other sites

    Changed Status from Feedback Requested to Closed

    Hi,We provided a JRXML that works on our side, but did not yet see the JRXML that does not work on your side.Feel free to reopen when you can provide more information.Thanks,Teodor
    Link to comment
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

  • Create New...