how to pass ambersand ( & ) as input parameter to a stored procedure ? [message #480713] |
Tue, 26 October 2010 11:42 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
nastyjillu
Messages: 211 Registered: February 2009
|
Senior Member |
|
|
Hi,
i have a stored procedure whose input parameter is a varchar2 datatype.
i created this procedure for an interface and tibco would be calling my procedure by passing input parameters.
my problem is when there is a input string with & (ambersand) then its not working.
even i tried to pass the parameter with & in TOAD, it asks me to enter value for string.
look at the sample code below which i wrote for testing purpose:
procedure is:
create or replace procedure testproc(p_in in varchar2)
is
begin
null;
end;
i pass parameter as given below:
begin
testproc('abc & def');
end;
if i run above script, it asks me to input some string value as it sees & in the string.
attached is the image that shows up in TOAD.
if i run below script it works. but i dont know how many &'s will be there in the input parameter. hence i cant do. and also TIBCO cant modify the input paramter while calling the procedure.
begin
testproc('abc &'||'def');
end;
thanks
jillu
|
|
|
|
|
|
|
|
|
|
|
|