dataimporthandler - How to do multiple replacements with Solr DIH RegexTransformer? -


With RegexTransformer I am using a Solr DataImportHandler and for a certain field, I want to change different patterns with different values. I <<>

Say, replacing Smith with Miller and John. A single replacement is easy:

  & lt; Field column = "text" regex = "Smith" replace = "miller" />  

But how to do the second part, replace John with?

Note that this is not asking for fancy reggaeks but how to implement more than one replacement is a single field.

I believe you use groupNames to specify Replacement can

From the example:

  & lt; Field column = "fullName" regex = "Mr (\ w *) \ b (. *)" GroupNames = "see firstName, lastName" />  

Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -