oracle oracle编译查看sql
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/859039/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Oracle compile view sql
提问by Marcus Leon
As part of our ANT based deploys we run some sql against an Oracle database.
作为基于 ANT 的部署的一部分,我们针对 Oracle 数据库运行一些 sql。
The deploys are set to fail if any sql
errors occur. (We do this using WHENEVER SQLERROR EXIT FAILURE ROLLBACK
in our SQL files and using the ant exec
command with failonerror=true
to run the sql).
如果sql
发生任何错误,部署将设置为失败。(我们WHENEVER SQLERROR EXIT FAILURE ROLLBACK
在 SQL 文件中使用并使用 antexec
命令执行此操作failonerror=true
以运行 sql)。
We would like to add to our deploy sql files some sql that will compile (or re-compile) certain views and have the deploy fail if the compile fails. Anyone know the sql (or whatever) that will allow us to do this?
我们想将一些 sql 添加到我们的部署 sql 文件中,这些 sql 将编译(或重新编译)某些视图,并且如果编译失败则部署失败。任何人都知道允许我们执行此操作的 sql(或其他)?
回答by araqnid
Do you need to do more than "ALTER VIEW xxx COMPILE"?
您需要做的不仅仅是“ALTER VIEW xxx COMPILE”吗?