Can you give me some idea about implementation of OOPS in Oracle?
相关问题
- how to define constructor for Python's new Nam
- Keeping track of variable instances
- Object.create() bug?
- Can I skip certificate verification oracle utl_htt
- std::vector of objects / pointers / smart pointers
相关文章
- node连接远程oracle报错
- oracle 11g expdp导出作业调用失败,提示丢包。
- 接口B继承接口A,但是又不添加新的方法。这样有什么意义吗?
- 执行一复杂的SQL语句效率高,还是执行多少简单的语句效率高
- Oracle equivalent of PostgreSQL INSERT…RETURNING *
- Difference between FOR UPDATE OF and FOR UPDATE
- NameError: name 'self' is not defined, eve
- Implementation Strategies for Object Orientation
That is a very large subject for a forum question. See the Oracle Database Object-Relational Developer's Guide for 100s of pages on this topic.
Oracle has supported objects since version 8.0 of the database (i.e. over a decade). However, it wasn't until 9iR2 that Oracle
TYPE
supported user-defined constructors and properly implemented polymorphism. In 11g they added support for a Java-esqueSUPER()
call. But Oracle still doesn't support private variables or private methods.As a consequence, OO programming hasn't really taken off in the Oracle world. People use Types to define collections in PL/SQL, which are especially useful for bulk processing. Pipelined functions are also neat, and open up an interesting little toolset.
I have used Oracle's object oriented functionality, and if I'm honest there are not many scenarios where it makes sense to choose types over regular PL/SQL. However, there are some situations where it can be useful. I have blogged about this at some length. Find out more.
edit
As Tuinstoel commented I linked to the wrong article on Adrian's site. They correctly divined the article I meant to link to, and I have now changed the link accordingly.
Here you have an example of using Oracle objects in combination with inheritance and polymorphism: link text . APC links to another page on this site, also about pipelined functions and objects but without inheritance and polymorphism.
And here is another one: link text
(Tom Kyte didn't like it but I post it anyway, I still feel a little sad that the discussion was in the end about commiting in PL/SQL instead of OO programming).