Apache OpenOffice (AOO) Bugzilla – Issue 116929
wrong auto-corrected formula (with mismatched delimiters): ends with odd ')'
Last modified: 2013-07-21 10:33:45 UTC
(I upgraded from OOO320m18 (I think) to the current OOO330m20 (Build: 9567) to check if the issue was gone--it is in the current version too.) I wanted to compare lists (modules in two httpd.conf files) using spreadsheet text functions to find differences in the lists. Entering this compound boolean function trying to find and match strings, but having mismatched string delimiters, results in OO Calc auto-correcting it with an unmatched parenthesis at the end. I typed/copied into a cell (e.g. F75, but it works on row 3 too.): =IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";'keep" ) ...Delimiters for 'keep" are mismatched Calc immediately adjusts this--without indicating an error--to: =IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";'keep" )) ....1...2..3....4.......4..3...3.......32...............1X Delete the extra right parenthesis, hit enter, and it is still there. Saving the file (.xls format), closing OO, and reopening the spreadsheet shows the formula further corrected (properly, I presume) to =IF(AND(IF(FIND("#";A75)=1;TRUE());IF(D75=B75;TRUE()));"add";"keep") ...1...2..3....4.......4.......443...3............4432.............1 The data in the cells A75:E75 are A75: #LoadModule userdir_module modules/mod_userdir.so B75: =MID(A75;FIND(" ";A75;1);10) C75: LoadModule userdir_module modules/mod_userdir.so D75: =MID(C75;FIND(" ";C75;1);10) E75: =IF(D75=B75;".";"x") F75: the bug-evoking formula above
'keep" is wrong and caused this unpredicted behavior. "keep" leaves the formula unchanged. Rev. 1503704 Win 7
The unnecessarily lengthy description distracted me, sorry.
IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";'keep" ) corrects to IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";'keep" )) instead to IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";"keep" ) however IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";"keep" )) corrects to IF (AND(IF(FIND("#";A75)=1);IF(D75=B75));"add";"keep" ) Rev. 1503704 Win 7
bug is confirmed.