> i have the string "You may earn 25k > dollars per week" stored in the field > "salary" > > i'm using 2 copyfields "salary_min" and "salary_max" with > source in "salary" > with those 2 datatypes > > salary is "text" > salary_min is "salary_min_text" > salary_max is "salary_max_text" > > so, i was expecting this: > > solr updates its index > solr copies the value from salary to salary_min and applies > the value with > the regex > solr copies the value from salary to salary_max and applies > the value with > the regex > > > but it's not working, it copies the value from one field to > another, but the > filter isn't applied, even if it's working as you could > see
Okey, that makes sense. copyField just copies the content. It has nothing to do with analyzers. Two solutions comes to my mind. 1-) If you are using data import handler, I think (i am not good with regex), you can use regex transformer to populate these two fields. http://wiki.apache.org/solr/DataImportHandler#RegexTransformer 2-) If not, you can populate these two field in a custom UpdateRequestProcessor. There is an example to modify and to start here : http://wiki.apache.org/solr/UpdateRequestProcessor