MySQL Forums
Forum List  »  Stored Procedures

Re: variables in WHERE
Posted by: Federico Razzoli
Date: March 24, 2005 07:39AM

I guess you are trying to search the string 'won'.

create procedure find_council(IN txtin VARCAHR(50))
begin
set txtin = concat('%',txtin,'%');
select * from council where 'Council Name' like txtin;
end

CALL FIND_COUNCIL ('won');

Without ' you are trying to pass a column to the procedure, but the column `won` does not exist.

Options: ReplyQuote


Subject
Views
Written By
Posted
4669
March 23, 2005 08:04PM
2516
March 24, 2005 02:53AM
Re: variables in WHERE
2607
March 24, 2005 07:39AM
2353
March 24, 2005 03:54PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.