-- -----------------------------------------------
-- USING SQL TO DEVELOP TIME ORIENTED APPLICATIONS
-- By : Richard T. Snodgrass
-- -----------------------------------------------
--
-- What is Bob's current position?
-- INCUMBENTS is temporal
-- By   : Bruce C. Huang
-- Date : Dec. 12, 1997
--
-- -----------------------------------------------
REM
REM Code Fragment 6.1 in Oracle 7.3
REM INCUMBENTS is temporal, POSITIONS is non-temporal.
REM
SELECT JOB_TITLE_CODE1
FROM   EMPLOYEES, INCUMBENTS, POSITIONS
WHERE  FIRST_NAME    = 'Bob'
   AND EMPLOYEES.SSN = INCUMBENTS.SSN
   AND INCUMBENTS.PCN= POSITIONS.PCN
   AND END_DATE = TO_DATE('3000-01-01','YYYY-MM-DD');
