Re: Package procedures can't call builtin's?

From: <adong_at_galaxy.gov.bc.ca>
Date: 12 May 93 13:31:24 -0700
Message-ID: <1993May12.133124.2450_at_galaxy.gov.bc.ca>


In article <1993May12.115058.27253_at_pyra.co.uk>, graeme_at_pyra.co.uk (Graeme Sargent) writes:

> In <1993May11.150441.2441_at_galaxy.gov.bc.ca> adong_at_galaxy.gov.bc.ca writes:
>

>>I'm writing my first stored package in Oracle 7 and am getting the following >>messages:  

>>39/11    PLS-00313: 'MESSAGE' not declared in this scope      
>>39/11    PL/SQL: Statement ignored                            
>>40/11    PLS-00313: 'BELL' not declared in this scope         
>>40/11    PL/SQL: Statement ignored                            
>>42/15    PLS-00201: identifier 'ERROR_CODE' must be declared  

>

 ...
> What's SQLPlus got to do with it? A Stored Procedure/Package is in the
> database, independent of any particular front-end.
>
> No, SQLFORMS built-ins are not automatically available in Stored
> Procedures/Packages only PL/SQL ones. Where are you expecting MESSAGE
> and BELL to send their output to? Stored Procedures execute in the
> server not the client, there is no terminal style of device to talk to.
>

You're right, I was under the incorrect assumption that stored procedures could contain any PL/SQL code as per the manual. The manual should have said any "pure" PL/SQL code. I just assumed that because it worked in the form that I could simply copy it into a package. That way I could have data overloading and simply recompile any code changes without having to recompile the forms using the procedure.

Guess I'll have to implement the error handling procedure in a standalone library form and have all the other forms reference it. Guess that also means that I'll have to recompile it and all the other forms referencing the procedure whenever I have code changes to the procedure.

Regards, Allan Dong Received on Wed May 12 1993 - 22:31:24 CEST

Original text of this message