TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
karthik parcha
NA
153
92.7k
How to replace single quotes in SP
Sep 12 2011 5:39 AM
Hi
this is my query
SELECT AccountNo, BusinessName FROM CustomerDetails WITH (NOLOCK) WHERE BusinessName like @BusinessName + '%' ...
When i execute my SP output Shouldbe like this
AccountNo BusinessName
10509 Anderson's "The Grocery Store".......
But when iexecut emy SP
--EXEC DBSP_SF_GetAccountsLikeAccNo '10509','Anderson's "The Grocery Store"'
Getting error like...........
Incorrect syntax near 's'.
Unclosed quotation mark after the character string ''.
So when i execute my SP adding another Apostrophe after anderson
like EXEC DBSP_SF_GetAccountsLikeAccNo '10509','Anderson''s "The Grocery Store"'
ite executed so i want to replace how to replace using replace function in SP
plz help me
Reply
Answers (
22
)
How to execute one function in all databses under one server using sqlserver2008?
Installation of sql server 2000 on Windows 7 Professional Edition