Hi,
Now I need a pattern to detect last name possibilities. I think this pattern will be slightly more complicated. Names that I see in the database are like:
Jones
Jones-Smith
Jones Smith (no hyphen)
O'Leary
Van Allen (no hyphen)
Vander Ark (no hyphen)
I think that this pattern will work but I would like public opinion to make sure I am getting this right:
^[a-zA-Z\-\s']+$
Can you think of any last names where this will not work? In testing it seems to work out alright.
Thanks,
Rob
Now I need a pattern to detect last name possibilities. I think this pattern will be slightly more complicated. Names that I see in the database are like:
Jones
Jones-Smith
Jones Smith (no hyphen)
O'Leary
Van Allen (no hyphen)
Vander Ark (no hyphen)
I think that this pattern will work but I would like public opinion to make sure I am getting this right:
^[a-zA-Z\-\s']+$
Can you think of any last names where this will not work? In testing it seems to work out alright.
Thanks,
Rob