Bug 69072 - FILEOPEN: .xlsx FLOOR() adds ,1 on every load
Summary: FILEOPEN: .xlsx FLOOR() adds ,1 on every load
Status: CLOSED DUPLICATE of bug 38592
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: Other Windows (All)
: medium normal
Assignee: Not Assigned
Whiteboard: BSA
Depends on:
Reported: 2013-09-07 15:27 UTC by JDGA
Modified: 2013-11-22 22:34 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:

Example spreadsheet demonstrating bug (4.61 KB, application/vnd.ms-excel)
2013-09-07 15:27 UTC, JDGA

Note You need to log in before you can comment on or make changes to this bug.
Description JDGA 2013-09-07 15:27:22 UTC
Created attachment 85397 [details]
Example spreadsheet demonstrating bug

Problem description:
When a .xlsm is opened, all FLOOR() formulae have a ,1 added to the end of their arguments, thus adding an argument. This happens even if it already has the maximum number of arguments (three), in which case the formula gives a 504 error the next time it is updated.

Steps to reproduce:
1. Create a .xlsm
2. Add a FLOOR() formula anywhere within it
3. Repeatedly save and load

Current behavior:
Formula has extra argument added to it each time, no matter how many arguments it already has (causing errors if more than three present)

Expected behavior:
Formula does not have extra argument added to it if it already has three.
Operating System: Windows 8
Version: rc
Comment 1 Mike Kaganski 2013-09-19 03:38:49 UTC
Reproducible with -, and also with AOO 4.0 under Win7x64.

When LO opens an OOXML file (not only .xlsm) with FLOOR or CEILING, they both are supplied with an extra parameter ";1". The fact that this happens upon opening may be seen from the OOXML source: LO shows one more argument than there is in the xml source (xl\worksheets\sheetN.xml).

It seems that xlsx doesn't accept FLOOR with three (or more) arguments (unlike xls, that accepts 3-argument FLOOR). Upon opening such file with 3+ arguments in FLOOR/CEILING, MS Excel complains about errors in file, and suggest repairing the file. When repaired, all such formulas are removed and the last computation result is left in the cells.

AOO cannot save xlsx, but it adds extra parameter when opens it, too.

Probably, the problem is somehow related to the fact that LO adds third parameter to FLOOR/CEILING when dealing with xls? But there only three parameters result, never 4 or more, and three parameters are OK in xls.

As it impairs interoperability, I raise severity back to normal.
Comment 2 Peter Ansell 2013-11-21 04:20:33 UTC
This sounds similar to 38592 which describes behaviour of adding extra arguments to CEILING for each cycle of editing, saving, closing and reopening XLSX files.
Comment 3 Peter Ansell 2013-11-21 05:37:52 UTC
Patch submitted to Gerrit for review:

Comment 4 Eike Rathke 2013-11-22 22:34:37 UTC

*** This bug has been marked as a duplicate of bug 38592 ***