|
Posted by Erland Sommarskog on 11/30/05 13:49
cyber0ne (cyber0ne1@gmail.com) writes:
>> SELECT *
>> FROM Table
>> WHERE 'string' LIKE '%'+Column+'%' ;
>
> That's returning all rows, regardless of the string.
Then it's time for the standard advice for questions of this type. And that
is that you should always include:
o CREATE TABLE statement for your table (preferrably simplified)
o INSERT statements with sample data.
o The desired result given the sample.
With just a narrative that may not be complete, there is a risk for
misunderstandings. Also, with the information above, it's simple to
post a tested solution.
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
[Back to original message]
|