SELECT qualifications FROM employee WHERE name = 'Peter Smith'; |
name
is not defined explicitly for class employee
but is inherited from its superclass person
.
SELECT * FROM employee WHERE age > 50; |
age
is defined for person
and thus inherited by employee
.
IsA
relationships can be used explicitly in query expressions.
Determines employees and everyone else over the age 50.
SELECT * FROM person WHERE age > 50; |
SELECT * FROM p IN person WHERE age > 50 AND p NOT IN employee; |