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: PROBLEM WITH CREATING A FUNCTION

Re: PROBLEM WITH CREATING A FUNCTION

From: Tim X <timx_at_spamto.devnul.com>
Date: 30 Jan 2003 22:56:17 +1100
Message-ID: <87hebqsvfi.fsf@tiger.rapttech.com.au>


>>>>> "Norman" == Norman Dunbar <Norman.Dunbar_at_lfs.co.uk> writes:

 Norman> And a semicolon after the first select as well :o) Cheers,

 Norman>> Niether of your SELECT statements are complete - you need  Norman>> some kind of FROM clause to complete each one.

 Norman>> Regards Kevin "The Rhythm Chronologist"

Not only that, I think you are on the wrong track conceptually with user defined functions you can call from within an SQL statement (if I understand what you were trying to do).

Also, the STRING should be replaced by VARCHAR2 and you need to specify what kind of parameters your function takes (i.e. IN, OUT or IN OUT). I think you need to think about what your function will be able to accept as arguments wrt columns in your select statement. Essentially, you will have a value representing each of the columns for EACH single ROW selected by your statement (i.e. the function will be called once for each row).

Have a look at the SQL reference manual and the PL/SQL reference manual at http://docs.oracle.com

Tim

-- 
Tim Cross
The e-mail address on this message is FALSE (obviously!). My real e-mail is
to a company in Australia called rapttech and my login is tcross - if you 
really need to send mail, you should be able to work it out!
Received on Thu Jan 30 2003 - 05:56:17 CST

Original text of this message

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