Re: stored function problem
Date: Tue, 04 May 1999 18:53:12 GMT
Message-ID: <7gnfmm$ngs$1_at_nnrp1.dejanews.com>
[Quoted] VARCHAR2 works fine, at least in Oracle 7.3... where I tested.
I first reproduced the problem using your sample code. Then I wrote the function with varchar2 as was suggested. It compiled OK.
Here is the text:
CREATE OR REPLACE FUNCTION
GET_CONTENT( SYSCODE IN VARCHAR2) RETURN VARCHAR2 AS
RCONTENT VARCHAR2(25);
BEGIN
SELECT CONTENT INTO RCONTENT
FROM SECRET
WHERE CODE=SYSCODE;
RETURN RCONTENT;
END;
INSERT INTO SECRET VALUES ('ABC','HLLOWORLD');
1 row created.
And: select Get_Content('ABC') from dual returns: HLLOWORLD
Bob Proffitt
Beckman/Coulter
Brea California
RTProffitt_at_beckman.com
[Quoted] -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own Received on Tue May 04 1999 - 20:53:12 CEST