Bug 54673 - [PATCH] Simple wildcard support in HLOOKUP, VOOLKUP, MATCH, COUNTIF
[PATCH] Simple wildcard support in HLOOKUP, VOOLKUP, MATCH, COUNTIF
Status: NEW
Product: POI
Classification: Unclassified
Component: POI Overall
3.10-dev
PC All
: P2 enhancement (vote)
: ---
Assigned To: POI Developers List
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2013-03-12 10:30 UTC by opensource
Modified: 2013-11-23 08:38 UTC (History)
0 users



Attachments
diff files generated using ant patchpackage task + excel LookupFunctionsTestCaseData.xls (18.32 KB, application/x-zip-compressed)
2013-03-12 10:30 UTC, opensource
Details
added testcases for complex wildcard values support (21.71 KB, application/x-gzip)
2013-03-14 10:36 UTC, opensource
Details
xls used by testcases to be copied into test-data\spreadsheet (34.77 KB, application/x-zip-compressed)
2013-03-14 10:37 UTC, opensource
Details

Note You need to log in before you can comment on or make changes to this bug.
Description opensource 2013-03-12 10:30:54 UTC
Created attachment 30041 [details]
diff files generated using ant patchpackage task + excel LookupFunctionsTestCaseData.xls

Support now wilcards 
? (question mark) Any single character
    For example, sm?th finds "smith" and "smyth"
* (asterisk) Any number of characters
    For example, *east finds "Northeast" and "Southeast"
~ (tilde) followed by ?, *, or ~A question mark, asterisk, or tilde
    For example, fy91~? finds "fy91?"

Combinations are supported and were extensively tested 
 
Testcases extended
* LookupFunctionsTestCaseData.xls
* org.apache.poi.ss.formula.functions.TestCountFuncs
* org.apache.poi.ss.formula.functions.TestMatch
Comment 1 opensource 2013-03-13 13:53:13 UTC
I've added more than 150 new unitary tests in LookupFunctionsTestCaseData.xls) show that complex wildcards are also supported by the core of apache poi and this patch!

new LookupFunctionsTestCaseData.xls will be uploaded here later
Comment 2 opensource 2013-03-14 10:35:42 UTC
added files
+ org.apache.poi.ss.formula.functions.TestFunctionsFromSpreadsheet
+ org.apache.poi.ss.formula.functions.TestMatchFunctionsFromSpreadsheet
+ MatchFunctionTestCaseData.xls



Limitations
Current patch has some limitations: Match don't support wilcards values with Match type
* 1 Largest value
* -1 Smallest value
for both simple and complex wildcard, testcases in MatchFunctionTestCaseData.xls are defined but skipped using <skip>

Use patch.tar.gz + spreadsheet.zip
Comment 3 opensource 2013-03-14 10:36:52 UTC
Created attachment 30048 [details]
added testcases for complex wildcard values support
Comment 4 opensource 2013-03-14 10:37:37 UTC
Created attachment 30049 [details]
xls used by testcases to be copied into test-data\spreadsheet