I want to search in a Solr database on full names. The documents in the database are from different sources, so the spelling of the name in the documents is not consistent. The spelling can be firstname lastname or lastname firstname. Also there can be one or more firstnames and one or more lastnames.
So if a name is: firstname: ALBERTO JORGE lastname: ALONSO CALEFACCION
The spellings can be: ALBERTO JORGE ALONSO CALEFACCION
ALBERTO J. ALONSO CALEFACCION
ALBERTO J ALONSO CALEFACCION
ALBERTO ALONSO CALEFACCION
and ALONSO CALEFACCION ALBERTO JORGE
ALONSO CALEFACCION ALBERTO J.
ALONSO CALEFACCION ALBERTO J
ALONSO CALEFACCION ALBERTO
I can search on the last names only with "ALONSO CALEFACCION"~0 with correct responses.
But how to search on all different spellings in one match? The search will be created by a program based on user input.
The search is more complicated because Spanish names can contain extra words like "y" and "de" without these words are required (in our case). So the name in the database could be something like: ALBERTO JORGE ALONSO Y CALEFACCION
Thanks for your help.
I use Solr 3.6