Question

In the 2nd edition of Database Systems: The Complete Book, the authors mention in section 10.3 that many relational DBMSs are now really "object-relational" DBMSs.

They mention nested relations, where the classic example of the Stars relation can be represented as:

Stars(name, [...], movies(title, year, length))

and references, where it can be represented as:

Stars(name, [...], movies({*Movies}))

The first form looks like it would introduce anomalies, but the second form looks fun. I would like to test it, but I cannot seem to find any of those "object-relational" DBMSs. Is there actually any implementation of this idea?

Was it helpful?

Solution

Oracle provides support for nested tables and varrays (varying array) http://docs.oracle.com/cd/B28359_01/appdev.111/b28371/adobjcol.htm

PostgreSQL also supports nested tables (see for example: http://architects.dzone.com/articles/nested-data-structures-and-non ) and a number of array-related features

MySQL does not support nested tables, but there's a SET data type to consider: http://dev.mysql.com/doc/refman/5.7/en/set.html

In general, whether using these features instead of a normalised approach is a good idea or not, probably depends on your application/data

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top