Bug 114406 - #NAME? error when using a number with percentage
Summary: #NAME? error when using a number with percentage
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.3.0.0.alpha0+
Hardware: All All
: high major
Assignee: Eike Rathke
URL:
Whiteboard: target:6.1.0 target:6.0.0.1 target:5....
Keywords: regression
Depends on:
Blocks:
 
Reported: 2017-12-11 13:48 UTC by Andreas Blochberger
Modified: 2017-12-12 17:41 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
Sheet demonstrating the problem (9.67 KB, application/vnd.oasis.opendocument.spreadsheet)
2017-12-11 13:48 UTC, Andreas Blochberger
Details
Original file created in Excel (6.65 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2017-12-11 13:50 UTC, Andreas Blochberger
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Blochberger 2017-12-11 13:48:02 UTC
Description:
See attached example. In cell B1 a value of "100%" is given. In cell C1 the formula: =A1/B1*100% 

The original sheet was opened from an XLSX. Sometimes the error occurs, but sometimes it does not.

When one tries to enter such a formula, LO replaces 100% with 1 automatically. 

Steps to Reproduce:
Open the attached sheet

Actual Results:  
The 100% does not work.

Expected Results:
It should be interpreted as 1 


Reproducible: Always


User Profile Reset: No



Additional Info:


User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:57.0) Gecko/20100101 Firefox/57.0
Comment 1 Andreas Blochberger 2017-12-11 13:48:40 UTC
Created attachment 138364 [details]
Sheet demonstrating the problem
Comment 2 Andreas Blochberger 2017-12-11 13:50:13 UTC
Created attachment 138365 [details]
Original file created in Excel
Comment 3 Eike Rathke 2017-12-11 14:39:40 UTC
Investigating.
Comment 4 Eike Rathke 2017-12-11 17:03:44 UTC
This happens only if the percent immediately follows a number, not an expression like (99+1)%, which is related to the fact that on manual input 100% is converted to 1.
Comment 5 Commit Notification 2017-12-11 17:24:01 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=f6b2349e880afa82f9267087fb48b6e4f8a9aa05

Resolves: tdf#114406 treat % as the operator that it is

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Eike Rathke 2017-12-11 17:31:47 UTC
Pending Jenkins build / review
https://gerrit.libreoffice.org/46254 for 6-0
https://gerrit.libreoffice.org/46255 for 5-4
Comment 7 Commit Notification 2017-12-11 22:04:37 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=b030bf19e29f031b0a640dd92c38d654785f1a99&h=libreoffice-6-0

Resolves: tdf#114406 treat % as the operator that it is

It will be available in 6.0.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 8 Commit Notification 2017-12-12 17:41:03 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-4-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=edb92e348f422cd4db9d356419e4c36b9a7a67c4&h=libreoffice-5-4-4

Resolves: tdf#114406 treat % as the operator that it is

It will be available in 5.4.4.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 9 Commit Notification 2017-12-12 17:41:15 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=51bb22f7a8f1d9fe02243aa58427d63916226793&h=libreoffice-5-4

Resolves: tdf#114406 treat % as the operator that it is

It will be available in 5.4.5.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.