In a mySQL db I have a table in which one field contains last names. About 99% of the 50,000+ records contain only a single name. But a few 'need' to contain two or more names. I have implemented this by using a pipe to separate the names which I then can explode into an array of names.
Problem: I need to search on the name field to select all records containing a search name (e.g., 'Smith' in 'Jones|Smith|Thompson'). A search on 'Smith' should only return 'Smith' and not 'Smithson'. Smith should be found regardless of the position within the "array".
My skill set is towards the advanced side for PHP and mySQL but below novice with REGEX. Any assistance would be greatly appreciated.
jdadwilson