Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Create Function issue

Re: Create Function issue

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Thu, 11 Apr 2002 19:15:40 +0200
Message-ID: <a3hbbus6gl6hr6r0pvdtir379kupvi6f2o@4ax.com>


On 11 Apr 2002 09:12:32 -0700, fshah01_at_hotmail.com (farhan) wrote:

>what is wrong with following Function?
>
>CREATE OR REPLACE FUNCTION PartLookUp(partno varchar2) RETURN varchar2
>AS
>begin
> select part_id, replacement_part_id from parts where part_id=partno;
>
> if parts.replacement_part_id <> '' then
> call PartLookUp(parts.replacement_part_id);
> end if;
>
> return parts.parts_id;
>
>end

Is this a quiz question? Can we earn anything by answering it? Or is it just *homework*
A function always returns a result. The result should be assigned to something.
Now, please draw the logical conclusion.

Regards

Sybrand Bakker, Senior Oracle DBA

To reply remove -verwijderdit from my e-mail address Received on Thu Apr 11 2002 - 12:15:40 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US