Home » SQL & PL/SQL » SQL & PL/SQL » Pl/Sql
Pl/Sql [message #1909] Mon, 10 June 2002 07:12 Go to next message
Nitin Jain
Messages: 7
Registered: October 2001
Junior Member
In Postgre to call a user defined function we can use Perform statement.

Example:
CREATE FUNCTION populate() RETURNS INTEGER AS '
DECLARE
-- Declarations
BEGIN
PERFORM my_function(); *************??????
END;

How this is implemented in Oracle?

' LANGUAGE 'plpgsql';

How this ids implemnted in Oracle.
Re: Pl/Sql [message #1915 is a reply to message #1909] Mon, 10 June 2002 22:00 Go to previous message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
In PL/SQL, the PERFORM keyword doesn't exist. You simply call the program unit:
CREATE FUNCTION populate() RETURNS INTEGER AS 
DECLARE
v_return number;
-- Declarations
BEGIN
v_return := my_function(x,y,z); -- A function returns always a value
my_procedure(...); -- A procedure can be called.
my_package.my_procedure_2; 
END;


MHE
Previous Topic: select result (by page)
Next Topic: Re: define view column as a PL/SQL functon
Goto Forum:
  


Current Time: Fri May 17 19:23:05 CDT 2024