DVE |
!!! какого "рожна" он лезет в "BOX.KK_LANG" а не в "tst.kk_LANG" |
Чего орешь, не в лесу
SQL> show user
USER is "SCOTT"
SQL> create or replace package my_pkg
2 is
3 procedure set_cnt;
4 end;
5 /
Package created.
SQL> create or replace package body my_pkg
2 is
3 procedure set_cnt
4 is
5 begin
6 DBMS_SESSION.SET_CONTEXT('new_cnt','attr','dummy');
7 end;
8 end;
9 /
Package body created.
SQL> show user
USER is "SYS"
SQL> create context new_cnt using scott.my_pkg;
Context created.
SQL> show user
USER is "SCOTT"
SQL> execute my_pkg.set_cnt
PL/SQL procedure successfully completed.
SQL> select sys_context('new_cnt','attr') from dual;
SYS_CONTEXT('NEW_CNT','ATTR')
--------------------------------------------------------------------------------
dummy
SQL> grant execute on my_pkg to master;
Grant succeeded.
SQL> show user
USER is "MASTER"
SQL> execute scott.my_pkg.set_cnt;
PL/SQL procedure successfully completed.
SQL> select sys_context('new_cnt','attr') from dual;
SYS_CONTEXT('NEW_CNT','ATTR')
--------------------------------------------------------------------------------
dummy