How this below insert query can be modified or escape single quote in SQL Server:
INSERT INTO <tblname> (title,desc)
VALUES
('Hen's Body','It's just best combination')
This query not run 开发者_StackOverflow中文版in SQL Server. I need similer solution to MySQL (like using backslash)as it is
INSERT INTO <tblname> (title,desc)
VALUES('Hen\'s Body','It\'s just best combination')
Regards
Double up the single quotes to escape them:
INSERT INTO ( title, description )
VALUES ( 'Hen''s Body', 'It''s just best combination' )
精彩评论