SQL quote problem
-
How can we do: insert into table (name) values ('nick's') in sql server. I tried using : insert into table (name) values ('nick\'s') insert into table (name) values ("nick's") but still could not find the solution. I need to execute the query not from stored procedure. Thanks.
Don't work hard, but work effectively. Web hosting | Buy stock | Option strategy | home mortgage
-
How can we do: insert into table (name) values ('nick's') in sql server. I tried using : insert into table (name) values ('nick\'s') insert into table (name) values ("nick's") but still could not find the solution. I need to execute the query not from stored procedure. Thanks.
Don't work hard, but work effectively. Web hosting | Buy stock | Option strategy | home mortgage
If you are coding in c# this might help you:
insert into table (name) values (@"nick's")
-
How can we do: insert into table (name) values ('nick's') in sql server. I tried using : insert into table (name) values ('nick\'s') insert into table (name) values ("nick's") but still could not find the solution. I need to execute the query not from stored procedure. Thanks.
Don't work hard, but work effectively. Web hosting | Buy stock | Option strategy | home mortgage
do it like this
insert into table (name) values ('Nick''s')
I know it will Help
Vuyiswa Maseko, Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding VB.NET/SQL7/2000/2005 http://vuyiswamb.007ihost.com http://Ecadre.007ihost.com vuyiswam@tshwane.gov.za
-
How can we do: insert into table (name) values ('nick's') in sql server. I tried using : insert into table (name) values ('nick\'s') insert into table (name) values ("nick's") but still could not find the solution. I need to execute the query not from stored procedure. Thanks.
Don't work hard, but work effectively. Web hosting | Buy stock | Option strategy | home mortgage
If you are doing this from code you should use named parameters, otherwise you will likely be vulnerable to SQL injection attacks.
Mark Churchill Director, Dunn & Churchill Pty Ltd Free Download: Diamond Binding: The simple, powerful, reliable, and effective data layer toolkit for Visual Studio.
Alpha release: Entanglar: Transparant multiplayer framework for .Net games.