Cool! suggestion: you might want to replace externalVal.toLowerCase().split(" ");
with externalVal.toLowerCase().split("\\s+");also I bet folks might have different ideas about what to do with hyphens, so maybe:
externalVal.toLowerCase().split("[-\\s]+");In fact why not make it a configurable parameter? Or - even better - use some other existing token analysis chain? I'm not sure how to fit that into Solr's architecture: can you analyze a field value and still access the unanalyzed text?
-Mike