Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
pattikay
Starting Member
36 Posts |
Posted - 2001-07-10 : 11:14:28
|
| I would like to return matches that have been stored with quotes , either single quotes or double quoteswhen i run the following queries i get correct matches :select not_noteid from notes where not_text like "%'sick'%"select not_noteid from notes where not_text = "'sick'"but when a stored procedure executes the following it gets the following error:Incorrect syntax near 'sick'.the string the stored procedure executes looks like this :select atd_idfrom attendance_detailswhereattendance_details.atd_complaintid in(select not_noteid from notes where not_text like "%'sick'%")The stored procedure uses sp_executesql to execute that statement.Thanks In advance.Edited by - pattikay on 07/10/2001 11:17:07 |
|
|
|
|
|