message problem [message #285906] |
Thu, 06 December 2007 01:13  |
salwa
Messages: 76 Registered: December 2007
|
Member |
|
|
declare
x varchar(100);
begin
x :=message('dasdadadaefd');
end;
its possiable
|
|
|
|
|
Re: message problem [message #285936 is a reply to message #285935] |
Thu, 06 December 2007 02:29   |
dhananjay
Messages: 635 Registered: March 2002 Location: Mumbai
|
Senior Member |
|
|
Quote: | Is the above value is a string. I don't thing so. So make it a string to store it.
|
can you prove that it;s not a string.
create or replace function string_test(p_string varchar2)
return varchar2 is
begin
return p_string;
end;
declare
x varchar2(100);
begin
x :=string_test('display as string');
dbms_output.put_line(x);
end;
regards,
[Updated on: Thu, 06 December 2007 02:34] Report message to a moderator
|
|
|
|
Re: message problem [message #285942 is a reply to message #285941] |
Thu, 06 December 2007 02:56   |
salwa
Messages: 76 Registered: December 2007
|
Member |
|
|
CREATE OR REPLACE procedure VALIDATE_OPERATION_WEB(br_code in varchar2,mk_user_name in varchar2,rightid in number)
is
RECORD_COUNT number;
v_data number;
begin
SELECT distinct 1 INTO RECORD_COUNT
FROM
test.USERINFO ,
test.USERROLE ,
test.ROLERIGHTS ,
test.RIGHTS
WHERE
test.USERINFO.ID = test.USERROLE.USERID
AND test.ROLERIGHTS.RIGHTSID = test.RIGHTS.ID
AND test.USERROLE.ROLEID = test.ROLERIGHTS.ROLEID
AND test.USERINFO.HOMEBRANCHID =to_number(br_code)
AND UPPER(test.USERINFO .USERNAME) = UPPER(mk_user_name)
AND test.RIGHTS.ID = rightid;
RAISE TOO_MANY_ROWS;
EXCEPTION
WHEN NO_DATA_FOUND THEN
raise_application_error(-20010,'User has no right to perform the operation ');
raise_application_error(-06512,'User has no right to perform the operation ');
WHEN TOO_MANY_ROWS THEN
NULL;
WHEN others THEN
raise_application_error(-20002,'Can not Use it ');
end;
/
this is my procedure
message will be 'User has no right to perform the operation '
|
|
|
|
|
|
|