Archives of the TeradataForum
Message Posted: Tue, 20 May 2003 @ 09:51:26 GMT
Subj: | | Re: Need help with Query |
|
From: | | Sanjaya Nagabhushan |
The Employee table has the column "Date_of_last_review" which is the date of last review. This obviates you to find the date when the
last review happened. You could join these 2 tables on matching "Employee_Number" & "Date_of_last_review/Date_Of_Review" column &
generate the report...
Sel employee_number, date_of_last_review, pay_rise_given
From employee e, review_date rd
Where (e.employee_number = rd.employee_number) AND
(e.date_of_last_review = rd.date_of_review);
Thanks,
Sanjay
|