All,
Facing a problem with the below query... 'DISTINCT with Order By Clause'.
Its working when we take the same column for distinct and order by then the query is working. But, in my case..there is a join b/w couple of tables.. and the distinct is for one column and the order by is for different table with different column.
Please suggest me a solution for this below query as the column in the distinct and column used for order by are different.
SELECT DISTINCT gl_cc.segment2
FROM gl_code_combinations gl_cc,
per_all_people_f req_emp,
per_all_assignments_f req_emp_assign
WHERE req_emp.person_id = req_emp_assign.person_id
AND gl_cc.code_combination_id =
req_emp_assign.default_code_comb_id
AND req_emp.full_name = 'xyz'
ORDER BY req_emp_assign.last_update_date DESC
Thanks