我刚刚安装了最新版本的PLJSON版本2.5.4
我成功地在oracle上安装了包,在sys用户下没有错误,但是其他用户无法访问PLJSON,例如运行测试示例sql文件。
作为sys/sysdba运行
SQL> connect sys@backup as sysdba
Enter password: ********
Connected.
SQL> @C:\sql\pljson-3.6.1\examples\ex12.sql
"true"
"true"
"true"
PL/SQL procedure successfully completed.从不同的用户结果运行它
SQL> connect orders@backup
Enter password: *****
Connected.
SQL> @C:\sql\pljson-3.6.1\examples\ex12.sql
obj pljson;
*
ERROR at line 2:
ORA-06550: line 2, column 7:
PLS-00201: identifier 'PLJSON' must be declared
ORA-06550: line 2, column 7:
PL/SQL: Item ignored
ORA-06550: line 4, column 3:
PLS-00320: the declaration of the type of this expression is incomplete or
malformed
ORA-06550: line 4, column 3:
PL/SQL: Statement ignored
ORA-06550: line 6, column 24:
PLS-00201: identifier 'PLJSON_PRINTER.PRETTY_PRINT_ANY' must be declared
ORA-06550: line 6, column 3:
PL/SQL: Statement ignored
ORA-06550: line 8, column 24:
PLS-00201: identifier 'PLJSON_EXT.PP' must be declared
ORA-06550: line 8, column 3:
PL/SQL: Statement ignored
ORA-06550: line 10, column 17:
PLS-00320: the declaration of the type of this expression is incomplete or
malformed
ORA-06550: line 10, column 3:
PL/SQL: Statement ignored我怎样才能得到它,使所有用户都可以访问它。
发布于 2022-03-16 19:24:23
我从未使用过它,但是--通常这样的问题是通过授予其他用户的权限来解决的--甚至是public。例如(连接为SYS,并假定包名为pljson)
grant execute on pljson to public;
create public synonym pljson for pljson;然后再次以orders的形式连接并运行
@C:\sql\pljson-3.6.1\examples\ex12.sqlhttps://stackoverflow.com/questions/71503138
复制相似问题