| RAJNISH |
Posted: Sep 04, 2008 03:22:28 AM |
Total Post: 92
Joined: Jan, 2007
|
Hi All,
can i call stand alone procedure from package.
my question is.i have one pkg i.e
create or replace package Test_pkg is
Procedure Testing_proc;------------I HAVE NOT DEFINE ON BODY.
end Test_pkg;
Testing_proc is stand alone not in Pakcage body.
can i call like this is it work?
--RAJNISH
|
|
|
vino |
| Posted: Sep 04, 2008 05:10:56 AM | |
|
Total Post: 357
Joined: Aug, 2008
|
Hi Rajnish,
The procedure you have specified will work. only begin and end statement is required to compile a proc
|
|
|
|
|
RAJNISH |
| Posted: Sep 04, 2008 05:37:05 AM | |
|
Total Post: 92
Joined: Jan, 2007
|
hi vino,
you meant to say i can call Stand Alone procedure via package specification without package body.
u meant to say that stand alone procedure should be there.
--RAJNISH
|
|
|
|
|
babi |
| Posted: Sep 04, 2008 05:38:37 AM | |
|
Total Post: 16
Joined: Aug, 2008
|
No. It is must to define testing_proc in package body. Otherwise it will raise error PLS-00323. Here is the demo.
create or replace package Test_pkg is
Procedure Testing_proc;
end Test_pkg;
create or replace procedure Testing_proc as
begin
dbms_output.put_line('HELLO');
end;
/
create or replace package body Test_pkg is
begin
NULL;
end Test_pkg;
It will raise the following error
PLS-00323: subprogram or cursor 'TESTING_PROC' is declared in a package specification and must be defined in the package body
|
|
|
|
|
| Time Zone: EDT |
Send this thread to your friend |