Oracle视图可以进行CRUD操作吗
我知道这有点模糊,但我对这些观点很陌生,并且正在努力了解它们的能力。
假设我使用表组合创建了一个由复杂查询创建的视图。如果我尝试在视图中编辑记录,视图是否足够智能,可以向后遍历创建视图的逻辑并在正确的表中编辑正确的值?
视图中是否允许编辑值?
谢谢!
I know this is kind of vague, but I'm new to views and am trying to learn what they're capable of.
Let's say I create a view created by complex queries using a combination of tables. If I tried to edit a record in the view, would the view be smart enough to go backwards through the logic which created the view and edit the correct value in the correct table?
Is editing a value even allowed in a view?
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这取决于:
http://download.oracle.com/ docs/cd/B28359_01/server.111/b28286/statements_8004.htm
请参阅该部分称为:“关于可更新视图的注释”
请注意,您始终可以在任何视图上创建一个
INSTEAD OF
触发器以使其可更新(您提供逻辑)。It depends:
http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/statements_8004.htm
See the section called: "Notes on Updatable Views"
Note that you can ALWAYS create an
INSTEAD OF
trigger on any view to make it updatable (you supply the logic).