Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Oracle views and function problems
I am using an Oracle 7.3 database and am having a strange problem. I am not
an Oracle DBA so forgive me if the naming I use is incorrect.
I have created an Oracle function that takes one input VARCHAR parameter and returns a VARCHAR2(5) value. I have created a view that selects records from a table and uses this function. When I perform a DESC on the view the function is of type VARCHAR2(2000). Does anybody have any ideas?
Below are the definitions of my function and view.
FUNCTION lineitem(accnbri in VARCHAR2)
RETURN VARCHAR IS tmp VARCHAR(5);
BEGIN
tmp := SUBSTR(accnbri, 12, 5);
return tmp;
END;
CREATE OR REPLACE VIEW V_ACTUALS AS SELECT lineitem(accnbri) as line_item,
glf_ldg_acct.* FROM glf_ldg_acct
Thanks,
Dave
-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/ Now offering spam-free web-based newsreading Received on Mon May 04 1998 - 23:05:42 CDT
![]() |
![]() |