Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Single quote
Message
De
04/03/2009 12:01:34
 
 
À
04/03/2009 04:02:04
Information générale
Forum:
Internet
Catégorie:
Active Server Page
Titre:
Divers
Thread ID:
01385403
Message ID:
01385528
Vues:
21
>Hi
>
>
>I have a problem with users entering ' in a field on a classic asp page which is then used to create an SQL string which then fails.
>
>Whats the quickest solution to this problem.
>
>The system is on maintenance only so I'm really looking for something that requires minimal changes.
>
>
>Thanks
>
>Nick

Before sending the string to the SQL Server replace all occurances of " ' " with " ` " (the character to the left of the "1" key.). To the user, they basically appear the same, but the SQL server will not throw an error. The " ' " character is a reserved character in SQL server.
Greg Reichert
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform