Issue 20312 - Data->Sort order is different to that expected by LOOKUP() function
Summary: Data->Sort order is different to that expected by LOOKUP() function
Status: CLOSED IRREPRODUCIBLE
Alias: None
Product: Calc
Classification: Application
Component: code (show other issues)
Version: OOo 1.1 RC4
Hardware: PC Linux, all
: P2 Trivial (vote)
Target Milestone: ---
Assignee: oc
QA Contact: issues@sc
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-29 14:13 UTC by noadwj
Modified: 2003-09-29 15:51 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
.sxc file demonstrating the sort-order v lookup()-order problem. (5.37 KB, application/octet-stream)
2003-09-29 14:14 UTC, noadwj
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description noadwj 2003-09-29 14:13:14 UTC
I have a large spreadsheet that uses the lookup() function to fill in some
fields on each row.  The key field is some characters which may be followed by a
'+' sign.

In OpenOffice.org 1.0.3.1 the sort order and the lookup() order were the same,
so that the lookup table had the key fields sorted by Data->Sort and everything
worked.

I started using OOo 1.1rc4 last week and I have just found out that my
spreadsheet does not work.  I have to manually swap the order of the lookup
table such that the '+' keys appear before the corresponding 'plain' keys,
otherwise the lookup() stops searching on the plain key and does not continue to
the '+' key.  I have a minimal spreadsheet that demonstrates the problem.  I'll
try to attach it to this report.  The steps to demonstrate the defect are:

1) Load the spreadsheet.
2) The top section contains the lookup table.
3) Observe the results in the 'Search' section - the results appear to be correct.
4) Use Data->Sort on the lookup table, sorting columns A and B by column A with
no range headings.
5) You will now observe that the 'Search' table contains incorrect data.
Comment 1 noadwj 2003-09-29 14:14:29 UTC
Created attachment 9788 [details]
.sxc file demonstrating the sort-order v lookup()-order problem.
Comment 2 frank 2003-09-29 15:31:11 UTC
Hi,

this is not a bug.

Starting with OOo1.1Beta2 regular expressions are enabled under tools
options spreadsheet calculate and are working. OOo 1.0.3.1 does not
have the regular expressions so the '+' will not be interpreted as such.

Simply switch of 'enable regular expressions in formulas' and all
works well.

Frank
Comment 3 frank 2003-09-29 15:51:37 UTC
closed worksforme