将 PL/JSON 与 Oracle APEX 4.0 集成
我尝试在 Oracle APEX 应用程序中使用 PL/JSON,但当我尝试运行 Hello, world 示例(当我从 SQL*PLUS 作为 sys 运行示例时,效果很好):
ORA-06550: line 2, column 20:
PLS-00905: object MY_SCHEMA.JSON is invalid
ORA-06550: line 2, column 20:
PL/SQL: Item ignored
ORA-06550: line 5, column 5:
PLS-00320: the declaration of the type of this expression is incomplete or malformed
ORA-06550: line 5, column 5:
PL/SQL: Statement ignored
ORA-06550: line 7, column 26:
PLS-00201: identifier 'JSON_EXT.GET_VARCHAR2' must be declared
ORA-06550: line 7, column 5:
PL/SQL: Statement ignored
我使用的 Oracle 数据库版本是 10g XE 。
我猜测我没有正确授予这些包的执行权限:JSON_EXT、JSON_PRINTER 和 JSON_PARSER。我尝试将这 3 个包的执行权限授予 public 和 APEX_PUBLIC_USER 但无济于事。如果有人能指出我正确的方向,我将非常感激。我在谷歌上搜索了几个小时,但还没有找到可以回答我的问题或帮助解释问题所在以及如何解决我的问题的帖子/页面。
提前致谢!
I am trying to use PL/JSON in my Oracle APEX application but get the following errors when I attempt to run a Hello, world example (which works fine when I run the example from SQL*PLUS as sys):
ORA-06550: line 2, column 20:
PLS-00905: object MY_SCHEMA.JSON is invalid
ORA-06550: line 2, column 20:
PL/SQL: Item ignored
ORA-06550: line 5, column 5:
PLS-00320: the declaration of the type of this expression is incomplete or malformed
ORA-06550: line 5, column 5:
PL/SQL: Statement ignored
ORA-06550: line 7, column 26:
PLS-00201: identifier 'JSON_EXT.GET_VARCHAR2' must be declared
ORA-06550: line 7, column 5:
PL/SQL: Statement ignored
The version of Oracle database that I am using is 10g XE.
I am guessing that I haven't granted execute privileges correctly on the packages: JSON_EXT, JSON_PRINTER, and JSON_PARSER. I have tried granting execute privileges on the 3 packages to public and APEX_PUBLIC_USER but to no avail. I would really appreciate it if someone could point me in the right direction. I have Google searched for several hours and have yet to come across a post/page that answers my problem or helps explain what is wrong and how I can go about resolving my problem.
Thanks in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您执行 DESC JSON_EXT,则没有 GET_VARCHAR2 函数(至少在版本 0.9.2 中)。有一个 GET_STRING 函数返回 VARCHAR2。
您链接到的页面使用 PL/JSON 版本 0.8.6,看起来他们在 0.9 中做了一些大的更改,
请尝试最新版本的包中的示例。
If you do a DESC JSON_EXT, there isn't a GET_VARCHAR2 function (at least in version 0.9.2). There is a GET_STRING function that returns a VARCHAR2.
The page you link to uses PL/JSON version 0.8.6, and it looks like they've done some biggish changes in 0.9
Try out the examples in the latest version of the package.