I have a join_table as follows for a single person with id = 123.
join_time
id subject join_date
123 MATH 03-MAY-19
123 MATH 12-MAR-15
123 CS 05-JUN-12
123 CS 24-JUL-12
123 CS 27-JUN-14
123 HIST 18-AUG-14
123 HIST 19-DEC-12
123 SCI 20-MAY-02
123 SCI 26-JUL-93
My oracle sql output should be 1 per subject with the latest joining date and also the subject should be formatted as below:
id subject join_date
123 Maths 03-MAY-19
123 Computer Science 27-JUN-14
123 History 18-AUG-14
123 Science 20-MAY-02
suggestions pls?