https://bugs.documentfoundation.org/show_bug.cgi?id=93812

            Bug ID: 93812
           Summary: Spreadsheet column aliases break when new row is
                    inserted
           Product: LibreOffice
           Version: 4.2.8.2 release
          Hardware: Other
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Calc
          Assignee: [email protected]
          Reporter: [email protected]

Steps to reproduce:

1. Create a new spreadsheet.
2. In cell $A1, enter the value 1.
3. Select the column A header so the entire column is selected, and alias it by
entering the name "FIRST" into the cell selection dropdown and pressing enter.
4. In cell $B1, enter the value 2.
5. Select the column B header so the entire column is selected, and alias it by
entering the name "SECOND" into the cell selection dropdown and pressing enter.
6. In cell $C1, enter the formula "=FIRST+SECOND" and notice that the
calculated value is 3.
7. Select all of row 2, right-click and select "Insert row above".
8. The expected behavior is that the value of $C1 remain unchanged, but notice
that cell $C1 now reports the error "#REF!". This is because the inserted row
has corrupted all the name aliases. If you click on the cell-selector dropdown
and select "Manage names", you can see all the name aliases now look like:

    "$Sheet1.$A$1:$A$#REF!".

A workaround is to manually define name aliases to include an end-row less than
the maximum number of rows.

For example, by default, setting a name alias currently generates a name entry
like:

    $Sheet1.$A$1:$A$1048576

Presumably, inserting a new row tries to increment the end value, which
overflows, causing an error. If you manually re-define this like:

    $Sheet1.$A$1:$A$10000

Then insertions can increment this value without overflowing, albeit this can
be a huge hassle to do if you need to define dozens of column aliases.

This bug seems to have been introduced in some 4.* release. I don't remember
having this problem in the 3.* release.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to