« first day (3057 days earlier)      last day (1261 days later) » 

2:04 PM
afternoon
 
 
2 hours later…
3:52 PM
Hi guys,

Can anyone help me get SQL to delete anything with the max date?

So far I have this to try and select it and then the plan was to trunc it but I can't even get the list :/

SELECT @max := max(D_TIME) from test_teamf_bat_log_audit;
SELECT * FROM test_teamf_bat_log_audit WHERE value = @max;
 
4:10 PM
what kind of value, you have in value e.g date field, else ?
 
4:45 PM
DateTime... I think I've fixed it though:

SELECT TO_CHAR(D_TIME, 'dd/mm/rr hh24:mi:ss'), E_TYPE, STATUS, F_TYPE
FROM test_teamf_bat_log_audit
WHERE TO_CHAR(D_TIME, 'dd/mm/rr hh24:mi:ss') = (SELECT max(TO_CHAR(D_TIME, 'dd/mm/rr hh24:mi:ss'))
FROM test_teamf_bat_log_audit)
@AndyK Thanks Andy. I do appreciate you responding :)
 

« first day (3057 days earlier)      last day (1261 days later) »