У меня есть запрос на оракула, который дает мне результат как:
sportsman1 coach1 result_of_function
sportsman1 coach2 result_of_function
sportsman2 coach3 result_of_function
Но мне нужно что-то вроде:
sportsman1
coach1 result_of_function
coach2 result_of_function
спортсмен2
coach3 result_of_function
select a.fullname as Sportsman, t.fullname as Coach, date_raz(a.dateinclub, b.dateovertrain) as MONTHS
from athlet a, trainer t,black_couch b
where t.id=a.couch and b.couch=t.id and b.athlete=a.id;
Что мне добавить в запрос?