You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by "cedric.walter" <ce...@innoveo.com> on 2013/01/29 16:08:57 UTC
Wildcard lookup values not supported yet
Hi all,
I have some excel that use a lot of Wildcard lookup values. And this is noo
supported in POI 3.9, as seen here in the code of the trunk
http://svn.apache.org/repos/asf/poi/trunk/src/java/org/apache/poi/ss/formula/fun
ctions/Match.java
private static LookupValueComparer createLookupComparer(ValueEval lookupValue,
boolean matchExact) {
if (matchExact && lookupValue instanceof StringEval) {
String stringValue = ((StringEval) lookupValue).getStringValue();
if(isLookupValueWild(stringValue)) {
throw new RuntimeException("Wildcard lookup values '" +
stringValue + "' not supported yet");
}
}
return LookupUtils.createLookupComparer(lookupValue);
}
private static boolean isLookupValueWild(String stringValue) {
if(stringValue.indexOf('?') >=0 || stringValue.indexOf('*') >=0) {
return true;
}
return false;
}
here is an example out of my excel
*_TableValues_Label
My Questions are
* Would it be difficult to develop this functionality? If i get guidance (what
has to be done) i would be ready to develop it and provide a patch.
Is there a excel way to get around this, some pointers or experience (i know it
is domains specific, but some guidance would be also appreciated)
Thanks
Cédric
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org