ASP.Net Issues
Friday, June 24, 2011
Select with LIKE and Parameter
SqlCommand
cmd
=
New
SqlCommand
(
"SELECT * FROM Empolyees WHERE (body LIKE '%' + @query + '%') OR (title LIKE '%' + @query + '%')"
)
cmd
.
Parameters
.
Add
(
"@query"
,
searchText
)
No comments:
Post a Comment
Newer Post
Home
Subscribe to:
Post Comments (Atom)
affiliate marketing
No comments:
Post a Comment