Friday, December 3, 2010

Searching All columns in one table one by one for a particular data in SQL Server

SELECT 
        * 
FROM 
        testview
WHERE 
        Username like '%' + @search + '%' 
OR 
        Description like '%' + @search + '%' 
OR  
        Title like '%' + @search + '%'

No comments:

Post a Comment