I would like to get the last date of records modified. Here is a sample simple SELECT:
SELECT
t01.name,
t01.last_upd date1,
t02.last_upd date2,
t03.last_upd date3,
'maxof123' maxdate
FROM
s_org_ext t01,
s_org_ext_x t02,
s_addr_org t03
WHERE
t02.par_row_id(+)= t01.row_id and
t03.row_id(+)= t01.pr_addr_id and
t01.int_org_flg = 'n';
How can I get column maxdate to display the max of the three dates?
Note: no UNION or sub/nested SELECT statements ;)
Greatest (t01.last_upd, t02.last_upd date2, t03.last_upd ) as maxdate
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With