Stored Procedure Parameter in Like Statement
eveloc | Posted 7:51am 3. April 2008 Server Time |
I have a stored procedure that accepts one parameter. I need to know how to write the SELECT statement that use the parameter in a LIKE statement. For example Select * from table1 where field1 like parameter. |
probinu | Posted 8:07am 3. April 2008 Server Time |
if I understand what you are asking, you want to create a stored procedure that accepts a parameter and selects records based on that parameter?
CREATE PROCEDURE xxxxxxxxx
@param VARCHAR(10)
AS
SELECT *
FROM table1
WHERE field1 like @param
make sense?
Reply to Post Stored Procedure Parameter in Like Statement
|
|
|