Is it possible to run an oracle package from sql plus without compiling it into a database?

I have an oracle package file (pbk with pks). I want to execute one of the methods in a package from sqlplus. I want to do this without compiling the package into an oracle database. A.

Is it possible? if so, how?

+3
source share
1 answer

You can use the anonymous PLSQL block to run something without compiling to the database, but objects that do not exist in the database (package, function, stored procedure, type, etc.) must be declared in the anonymous PLSQL block.

, (), , /etc, PLSQL:

DECLARE

  FUNCTION your_fnc() RETURN ... AS ...

BEGIN

  SELECT your_fnc()
    FROM DUAL;

END;
+7

Source: https://habr.com/ru/post/1773282/


All Articles