![]() |
|
Archives of the TeradataForumMessage Posted: Mon, 02 Jun 2008 @ 21:03:27 GMT
I think some thing like this will work. Also don't forget the trim....
replace macro myMacro
(last_Name char(30))
as (
select Trim(Last_Name) (char(30)) as l_Name
from db.Name
where l_Name like '%' || trim(:Last_Name) || '%' ;);
Then you can call it as follows:
exec myMacro ('khan')
Thanks!
| ||||||||||||||||||||||||||||||||||||||||||||||||
| | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
|
| ||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
| Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||