Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Search for a dash
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Versions des environnements
SQL Server:
SQL Server 2012
Application:
Web
Divers
Thread ID:
01603942
Message ID:
01603944
Vues:
52
>But, if I have this:
>
>
>DECLARE @Title Varchar(50)
>
>SET @Title='Michel F-%'
>
>SELECT Client.Numero FROM Client WHERE Client.Title LIKE @Title
>
>
>...it will not find anything, even if I have some title starting with Michel F-ournier, for example.
>
>I assume there is a conversion that has to be done on such special character.

That works for me just fine. You sure your data doesn't have a hyphen instead of a dash?

45 is a dash
173 is a hyphen

Also, you can save a line by doing DECLARE @Title Varchar(50) = 'Michael F-%'
Brandon Harker
Sebae Data Solutions
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform