| Summary: | EDITING: FIND and SEARCH functions don't use an array as first parameter in array formula | ||
|---|---|---|---|
| Product: | LibreOffice | Reporter: | m_a_riosv <miguelangelrv> |
| Component: | Calc | Assignee: | Not Assigned <libreoffice-bugs> |
| Status: | CLOSED NOTABUG | ||
| Severity: | normal | CC: | erack, ilmari.lauhakangas, raal, winfrieddonkers |
| Priority: | medium | ||
| Version: | Inherited From OOo | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
| Crash report or crash signature: | Regression By: | ||
| Attachments: |
File showing the bug
sample with countif |
||
Eike, Winfried: what do you think about this? (In reply to Buovjaga from comment #1) > Eike, Winfried: what do you think about this? My 2 cents: FIND, SEARCH and EXACT look like good working functions, compliant with ODFF1.2 and using texts as arguments 1 and 2. If ranges are given for arguments 1 and 2 and the function is entered as an array function, the functions return the values for the array - provided that the ranges of argument 1 and 2 have the same size (rows, columns). It doesn't look like a bug to me, more like unsupported use. I wouldn't know what FIND is supposed to do with the arguments in FIND(E2:E3;A2:C11). There's nothing wrong. In array mode, for FIND(E2:E3;A2:C11) the E2:E3 creates a column vector of 2 elements and A2:C11 a matrix of 3x8. The column vector is repeatedly used for each column of the 3x8 matrix, hence for the second column results are 5 and 1 and no result for column one and three. The column vector has only two elements, so for all columns starting at row 3 of the matrix there's no result. Created attachment 127652 [details] sample with countif (In reply to Winfried Donkers from comment #2) > It doesn't look like a bug to me, more like unsupported use. Looks like, FIND has my expected result with only one of the arguments as array. > I wouldn't know > what FIND is supposed to do with the arguments in FIND(E2:E3;A2:C11). Count cells that contain E2 or E3. With the same ranges as argument =SUMPRODUCT(COUNTIF(A2:C11;".*"&E2:E3&".*")) works fine, although needs regular expressions. I guess because the first argument in COUNTIF is treated in a different way with array expressions. |
Created attachment 127134 [details] File showing the bug With a formula like =SUMPRODUCT(NOT(ISERROR(FIND(E2:E3;A2:C11)))) FIND doesn't find for values in E2:E3, looks if it finds some of them.