Welcome to WebmasterWorld Guest from 54.159.44.227

Forum Moderators: ocean10000

Message Too Old, No Replies

Inputting single code string data

     

pwint

4:30 pm on Aug 22, 2005 (gmt 0)

10+ Year Member



Hi
I have a problem in inputing single code(') string into the SQL database. I wrote in ASP language and connect to the SQL server to insert the data.
If the data contains single code string (e.g women's group)the syntax error appears and it stops.
I tried to change the double code(")instead of single one to insert the data and then, it also has error "does not permit column name ...." or something like that.
How can i solve the problem to input the data that contains single code(')?
Any help appreciated. Thanks.

mattglet

4:53 pm on Aug 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Here's a past post that includes a function you can call (see the last post).

[webmasterworld.com...]

mrMister

7:03 pm on Aug 22, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Simply replacing the quotes is a bad habit to get in to. You create a lot of security vulnerabilities by using ad-hoc SQL statements like that.

Use your favourite search engine and search for information on parameterized SQL queries in ASP.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month