Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SELECT O'Brian, OBrian, O Brian
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
00410134
Message ID:
00410178
Vues:
13
>What's the best SELECT technique to use to grab all of the O'Brian's from the last name field. They could be stored as
>
>O'Brian
>OBrian
>O Brian
>
>We need to be able to allow the user to enter "Ob" in a text box and get people who's last name starts with "Ob", including all the variations on O'Brian. The same will apply with McDonald, Mc Donald...you get the picture.
>
>Any ideas??



Jim,

I don't have a perfect answer, but using WHERE LastName LIKE 'o[ '']b%' would find the first and third version of O'Brian, but not the second.

Hope this helps!
Sylvain Demers
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform