Re: Unable to get Last Record..
Top 1 isn't MySQL syntax.
Your query without the Order By and Limit clauses will return the specified max.
So the update cmd would be ...
update tdds.discrete_data d
set d.dd_auto_purge=1
where d.dd_acquired_ts < (
SELECT Max(dd_acquired_ts)
FROM tdds.discrete_data
where dd_acquired_ts < 1493152486000
)
ORDER BY d.dd_acquired_ts asc
LIMIT 100000;
Subject
Written By
Posted
Re: Unable to get Last Record..
May 25, 2017 11:15AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.