Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
REPLACE apostrophe
Message
 
 
À
26/06/2008 12:25:33
Jay Johengen
Altamahaw-Ossipee, Caroline du Nord, États-Unis
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Versions des environnements
SQL Server:
SQL Server 2000
Divers
Thread ID:
01326975
Message ID:
01326976
Vues:
16
>I need to replace an apostrophe with an empty string. How do I do that? This gives an error.
>
>SET @DocumentName = REPLACE(@DocumentName,'''','')	
>
declare @Doc varchar(max)
set @Doc = 'test''test'
set @doc = replace(@Doc,quotename(''''),'')
set @Doc = 'test''test'
set @doc = replace(@Doc,'''','')
select @doc
You're missing one extra '
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform