Strange objectrelational things…
Is this cool, isnt it?
Some objectrelational features from Oracle where i´ve current inuse are very cool. For instance this following codesnip:
UPDATE TRAINER SET TRAINED_ALSATIANS =
(CAST (MULTISET(
SELECT E FROM(
SELECT REF(P) E FROM FEMALE P UNION ALL SELECT REF(P) E FROM MALE P
) WHERE DEREF(E).NAME = ‘Lessi’ OR DEREF(E).NAME = ‘Hans’ OR DEREF(E).NAME = ‘Freya’ OR DEREF(E).NAME = ‘Heinrich’ ) AS ALSATiAN_LIST)) WHERE NAME = ‘Freddy’;
To starting with a little bit more OOP-Paradigms to bring this to a revealed state (in my mind and in the oracle database) it is in some cases very curious - i guess. Here in this sample code we have no opportunity to retrive in “one select statement” a supertype set of a subtype called MALE and FEMALE(both are devided in object-tables). So we have to reunion(what a adorable wordphrase) this. So we can retrive all things, we need to setting up the particular references so that freddy has something to do with his dogs ![]()
Comments
Leave a Reply

Sebastian Wenzky works since october 09 as a ecm-consultant at Westernacher in Stuttgart. Alfresco, Spring, Hibernate, JBPM and - to much - coffee are now his companions. The corresponding company the right way to go.